@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap");

a {
  text-decoration: none; 
  color: inherit;        
}

:root {
    --primary-color: #6e2f23;
    --secondary-color: #9f6741;
    --extra-light: #f3f4f6;
    --white: #ffffff;
    --gradient-1: linear-gradient(to right, #020202, #100b04, #020202);
    --gradient-2: linear-gradient(to bottom, #a66639, #100b04);
    --max-width: 1200px;
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  scrollbar-color: #9f6741; 
}


.skills {
  padding: 4rem 2rem;
  text-align: center;
}

.skills h2 {
  font-size: 2rem;
  margin-bottom: 6rem;
}

.skills__marquee {
  overflow: hidden;
  position: relative;
  width: 100%;
}

.skills__track {
  display: flex;
  gap: 3rem;
  animation: scrollLogos 20s linear infinite;
  width: max-content;
}

.skills__track img {
  height: 60px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 5px rgba(255,255,255,0.3));
  transition: transform 0.3s ease;
}

.skills__track img:hover {
  transform: scale(1.2);
}

@keyframes scrollLogos {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Mobile */
@media (max-width: 768px) {
  .skills__track img {
    height: 40px;
  }
}


.section__container {
  max-width: var(--max-width);
  margin: auto;
  padding: 5rem 1rem;
}

.section__header {
  margin-bottom: 1rem;
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
}

.section__description {
  max-width: 600px;
  margin-inline: auto;
  color: var(--extra-light);
  text-align: center;
  line-height: 1.75rem;
}

.btn {
  position: relative;
  padding: 0.75rem 1.8rem;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 3rem;
  cursor: pointer;
  overflow: hidden;
  z-index: 1;
  transition: all 0.3s ease;
}

.btn:hover {
  color: #fff;
  border-color: #fff;
  box-shadow: 0 0 25px rgba(255,255,255,0.8), 0 0 50px rgba(158,106,255,0.5);
  transform: scale(1.05);
}


img {
  width: 100%;
  display: flex;
}

a {
  text-decoration: none;
}

.logo {
  display: inline-block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  border-radius: 100%;
}

html,
body {
  scroll-behavior: smooth;
  height: 100%;
}

body {
  font-family: "Montserrat", sans-serif;
  color: var(--white);

  /* 🔥 Dégradé galaxie statique (non animé) */
  background: var(--gradient-1);
  background-size: cover; 
  scroll-behavior: smooth;
  overflow-x: hidden;
  position: relative;   /* ✅ référence z-index */
  z-index: 0;           /* ✅ au lieu de rien ou -1 */
}

/* 🌌 Particules étoilées (Safari friendly) */
body::before {
  content: "";
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0; /* ✅ plus de -1 */

  background-image: 
    radial-gradient(3px 3px at 35px 90px, #ffffff, transparent),
    radial-gradient(3px 3px at 180px 45px, #ffffffcc, transparent),
    radial-gradient(3px 3px at 260px 210px, #ffffff, transparent),
    radial-gradient(3px 3px at 120px 300px, #ffffffaa, transparent),
    radial-gradient(3px 3px at 340px 150px, #ffffff, transparent);

  background-size: 400px 400px;
  animation: stars 60s linear infinite;

  filter: drop-shadow(0 0 6px #ffffffcc) drop-shadow(0 0 12px #66ccff88);
  transform: translateZ(0); 
  will-change: transform;
}

/* ✨ Animation des étoiles */
@keyframes stars {
  from { transform: translateY(0); }
  to   { transform: translateY(-400px); }
}

/* ✅ Tous les blocs passent au-dessus */
nav, header, section, footer {
  position: relative;
  z-index: 1;
}




nav {
  position: fixed;
  isolation: isolate;
  top: 0;
  width: 100%;
  max-width: var(--max-width);
  margin: auto;
  z-index: 9;
}

.nav__bar {
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  background: rgba(0, 0, 0, 0.11);     
  backdrop-filter: blur(10px);        
  -webkit-backdrop-filter: blur(10px);
}

.nav__logo {
  height: 45px;         
  width: 45px;          
  border-radius: 50%;  
  object-fit: cover;    
  display: block;
  box-shadow: 0 0 10px rgba(0,0,0,0.4);
  transition: all 0.3s ease;
}

.nav__logo:hover {
  transform: scale(1.05);
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.9))
          drop-shadow(0 0 20px rgba(158, 106, 255, 0.6))
          drop-shadow(0 0 40px rgba(158, 106, 255, 0.4));
}


.nav__bar a {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--white);
}

.nav__menu__btn {
  font-size: 1.5rem;
  color: var(--white);
  cursor: pointer;
}

.nav__links {
  list-style: none;
  position: absolute;
  width: 100%;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  backdrop-filter: blur(10px);        
  -webkit-backdrop-filter: blur(10px);
  transform: translateY(-100%);
  transition: 0.5s;
  z-index: -1;
  visibility: visible;  
  opacity: 1; 
}

@media (width < 768px) {
.nav__links {
    visibility: hidden;  
  opacity: 0; 
  }
  .btn{
    color: #fff;
    border-color: #fff;
    box-shadow: 0 0 25px rgba(255,255,255,0.8), 0 0 50px rgba(158,106,255,0.5);
  } 
}

.nav__links.open {
  transform: translateY(0);
  opacity: 1;                
  visibility: visible;
}

.nav__links a {
  color: var(--white);
  transition: 0.3s;
}

.nav__links a:hover {
  color: var(--secondary-color);
}

.btn__large {
  display: none;
}

.header__container {
  padding-top: 8rem;
  display: grid;
  gap: 2rem;
  isolation: isolate;
}

.header__content {
  text-align: center;
}

.header__content h1 {
  display: inline-block;
  font-size: 3rem;
  font-weight: 700;
  line-height: 1.2em;
  padding-bottom: 0.2em;
  text-shadow: 0 0 8px rgba(255,255,255,0.8), 0 0 50px rgba(76, 53, 21, 0.5);
}





.header__content .section__description {
  margin-bottom: 2rem;
}

.header__image {
  position: relative;
  isolation: isolate;
  z-index: -1;
}

.header__image img {
  max-width: 450px;
  margin-inline: auto;
  border-radius: 2rem;
  box-shadow: 0 0 25px rgba(255,255,255,0.8), 0 0 50px rgba(158,106,255,0.5);
}

@media (width < 888px) {  
.header__image img{
  box-shadow: none;
}
}

.header__image::after {
  position: absolute;
  content: "KILLIAN HAJO";
  letter-spacing: 1.5rem;
  opacity: 0.8;
  right: 1rem;
  top: 50%;
  transform: translate(50%, -50%) rotate(90deg);
   text-shadow: 
    0 0 5px #ffffff,
    0 0 10px #e37d24,
    0 0 20px #c8741a,
    0 0 40px #ffffff;
}

.about__container {
  display: grid;
  gap: 2rem;
}

.about__image {
  position: relative;
  isolation: isolate;
  max-width: 400px;
  margin: auto;
}

.about__img {
  border-radius: 2rem;
}

.about__bg-1,
.about__bg-2 {
  position: absolute;
  max-width: 50px;
  z-index: -1;
}

.about__bg-1 {
  top: 0;
  left: 0;
}

.about__bg-2 {
  right: 0;
  bottom: 0;
}

.about__content {
  text-align: center;
}

.about__content .section__description {
  margin-bottom: 2rem;
}

.service__grid {
  margin-top: 2rem;
  display: grid;
  gap: 1rem;
}

.service__card {
  padding: 2rem 1rem;
  text-align: center;
  background-color: #ffffff2b;
  border-radius: 1rem;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}


.service__card span {
  display: inline-block;
  margin-bottom: 1rem;
  font-size: 2rem;
}

.service__card h4 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  font-weight: 700;
  transition: all ease 0.5s;

}

.service__card p {
  color: var(--extra-light);
  line-height: 2rem;
  transition: all ease 0.5s;
  cursor: default;
}

.service__card:hover {
  h4{
    transform: scale(1.05);
  }
  p{
  transform: scale(1.05);
  text-shadow: 0 0 1px #ffffff, 0 0 2px #ffffff, 0 0 2px #000000, 0 0 4px #ffffff;
  }
}

.portfolio__grid {
  margin-top: 2rem;
  display: grid;
  gap: 1rem;
  background-color: transparent !important; /* pas de nouveau fond */
  isolation: unset !important;              /* évite de couper le ::before */
  -webkit-transform: translateZ(0);         /* patch Safari */
  will-change: transform;
}

.portfolio__card {
  overflow: hidden;
  border-radius: 1rem;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
}

.portfolio__card img {
  width: 100%;
  height: 100%;
  object-fit: contain;   
  background: #000;      
  display: block;
transition: transform 0.5s ease;
}

.portfolio__card video {
  width: 100%;
  height: 100%;
  object-fit: contain;   
  background: #000;      
  display: block;
transition: transform 0.5s ease;
pointer-events: none;
}


.portfolio__card:hover img {
  transform: scale(1.1);
}

.portfolio__card:hover video {
  transform: scale(1.1);
}

.portfolio__banner {
  background-color: #ffffff2b;
  margin-top: 2rem;
  padding: 2rem;
  display: grid;
  gap: 2rem;
  text-align: center;
  border-radius: 1rem;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}

.portfolio__banner__card span {
  display: inline-block;
  margin-bottom: 0.5rem;
  font-size: 1.5rem;
}

.portfolio__banner__card h4 {
  font-size: 1.2rem;
  font-weight: 600;
}

.portfolio__banner__card p {
  font-weight: 500;
}

.contact__container {
  text-align: center;
}

.contact__container .logo {
  margin-bottom: 1rem;
}

.contact__socials {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.contact__socials a {
  padding: 7px 10px;
  font-size: 1.5rem;
  color: var(--white);
  background: rgba(0, 0, 0, 0);
  border-radius: 100%;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.1);
  transition: 0.3s;
}

.contact__socials a:hover {
  background: black;
  box-shadow: 0 0 25px rgba(255,255,255,0.8), 0 0 50px rgba(158,106,255,0.5);
}

.footer {
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--extra-light);
  text-align: center;
}

/*Contact*/

.modal {
  display: none; /* caché par défaut */
  position: fixed;
  z-index: 99;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.888);
  backdrop-filter: blur(5px);
  justify-content: center;
  align-items: center;
}

.modal__content {
  background: #ffffff2b;
  padding: 2rem;
  border-radius: 1rem;
  max-width: 500px;
  width: 90%;
  box-shadow: 0 0 25px rgba(255,255,255,0.8), 0 0 50px rgba(158,106,255,0.5);
  text-align: center;
  animation: fadeIn 0.3s ease;
}

.modal__close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 2rem;
  color: white;
  cursor: pointer;
}

.contact__form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact__form input,
.contact__form textarea {
  padding: 0.8rem;
  border-radius: 0.5rem;
  border: none;
  outline: none;
  background: rgba(255,255,255,0.2);
  color: white;
  font-size: 1rem;
}

.contact__form input::placeholder,
.contact__form textarea::placeholder {
  color: rgba(255,255,255,0.7);
}

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

/* Messages de succès / erreur */
.form__message {
  margin-top: 1rem;
  font-size: 0.95rem;
  text-align: center;
  font-weight: 600;
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}

.form__message.show {
  opacity: 1;
  transform: translateY(0);
}

.form__message.success {
  color: #4caf50; /* vert */
  text-shadow: 0 0 8px rgba(76, 175, 80, 0.6);
}

.form__message.error {
  color: #f44336; /* rouge */
  text-shadow: 0 0 8px rgba(244, 67, 54, 0.6);
}

/* Champ fichier custom */
.file-input {
  display: none; /* on masque le vrai input */
}

.file-label {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 3rem;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 0.5rem;
}

.file-label:hover {
  border-color: #fff;
  box-shadow: 0 0 25px rgba(255,255,255,0.8), 
              0 0 50px rgba(158,106,255,0.5);
  transform: scale(1.05);
}

/* Nom du fichier sélectionné */
.file-name {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.8);
  text-align: center;
}



/*Contact*/

@media (width > 576px) {
  .service__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .portfolio__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .portfolio__banner {
    grid-template-columns: repeat(2, 1fr);
    text-align: left;
  }
}

@media (width > 768px) {
  nav {
    padding: 2rem 1rem;
    position: static;
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .nav__bar {
    padding: 0;
    background-image: none;
  }

  .nav__menu__btn {
    display: none;
  }

  .nav__links {
    padding: 0;
    width: unset;
    position: static;
    transform: none;
    flex-direction: row;
    background-image: none;
  }

  .nav__links a:hover {
    color: var(--secondary-color);
  }

  .nav__links li:last-child {
    display: none;
  }

  .btn__large {
    display: flex;
  }

  .header__container {
    padding-top: 5rem;
    grid-template-columns: repeat(4, 1fr);
    align-items: center;
  }

  .header__image {
    grid-area: 1/3/2/5;
  }

  .header__image img {
    margin-inline-start: unset;
  }

  .header__content {
    grid-area: 1/1/2/4;
    text-align: left;
  }

  .header__content h1 {
    font-size: 6rem;
    line-height: 6rem;
    text-align: left;
  }

  .header__content .section__description {
    text-align: left;
    margin-inline-start: unset;
  }

  .about__container {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .about__content,
  .about__content :is(.section__header, .section__description) {
    text-align: left;
  }

  .service__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .portfolio__container :is(.section__header, .section__description) {
    text-align: left;
    margin-inline-start: unset;
  }

  .portfolio__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .portfolio__banner {
    grid-template-columns: repeat(3, 1fr);
  }
}

