:root {
    --bg-color: #0d0907;
    --orange: #ff7d25;
    --orange-bright: #ff954f;
    --blue-light: #4fc3f7;
    --white-off: #fbf4e9;
    --font-main: 'Roboto', sans-serif;
    --font-name: 'Red Rose', serif;
    --font-polaroid: 'Special Elite', cursive;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

/* 1. CONFIGURATION DE BASE */
html {
    /* Couleur de fond de sécurité pour le scroll élastique (rubber band) */
    background-color: var(--bg-color);
    height: 100%;
}

body {
    /* IMPORTANT : Transparent pour laisser voir le fond fixe derrière */
    background-color: transparent;
    color: var(--white-off);
    font-family: var(--font-main);
    overflow-x: hidden;
    width: 100%;
    min-height: 100vh;
    overscroll-behavior-y: none;
    display: flex; 
    flex-direction: column;
}

/* 2. LES CALQUES D'ARRIÈRE-PLAN (Z-INDEX 0 et 1) */

/* Le fond spatial (Gradient + Étoiles + Orbes) */
.space-background {
    position: fixed; 
    /* Inset 0 force le calque à toucher les bords physiques de l'écran */
    inset: 0; 
    width: 100%; 
    height: 100%;
    /* 100dvh s'adapte dynamiquement aux barres d'outils mobile */
    height: 100dvh; 
    /* Z-INDEX 0 : Tout en bas, mais visible */
    z-index: 0; 
    overflow: hidden;
    background: radial-gradient(ellipse at bottom, #070710 0%, #090A0F 100%);
}

/* Le grain (Noise) */
.noise-overlay::before {
    position: fixed; 
    inset: 0;
    width: 100%; 
    height: 100%; 
    content: "";
    opacity: 0.35;
    mix-blend-mode: overlay;
    /* Z-INDEX 1 : Juste au-dessus du fond, pour texturer les orbes */
    z-index: 1; 
    pointer-events: none;
    background: url(https://cdn.shopify.com/s/files/1/0564/7617/2332/files/GrainBackround.gif?v=1667804647);
    filter: contrast(170%) brightness(80%);
}

/* Les éléments DANS le fond (doivent rester dans le conteneur z-index 0) */
.gradient-orb {
    position: absolute; border-radius: 50%; filter: blur(130px); opacity: 0.4; will-change: transform;
}
.orb-orange {
    width: 800px; height: 800px;
    background: radial-gradient(circle, var(--orange) 0%, transparent 65%);
    top: -300px; left: -200px;
    animation: moveOrb 30s ease-in-out infinite alternate;
}
.orb-blue {
    width: 700px; height: 700px;
    background: radial-gradient(circle, var(--blue-light) 0%, transparent 60%);
    bottom: -20%; right: -15%;
    animation: moveOrb 40s ease-in-out infinite alternate-reverse;
}
@keyframes moveOrb {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 100px) scale(1.1); }
}

.stars-container, #shooting-stars-container {
    position: absolute; width: 100%; height: 100%; pointer-events: none;
}
.star {
    position: absolute; background: white; border-radius: 50%;
    box-shadow: 0 0 4px rgba(255,255,255,0.8);
    will-change: transform, opacity;
}
.shooting-star {
    position: absolute; height: 2px; background: linear-gradient(90deg, rgba(255,255,255,1), transparent);
    border-radius: 999px; filter: drop-shadow(0 0 6px rgba(255,255,255,1)); opacity: 0;
}


/* 3. LE CONTENU (Z-INDEX 10) */
/* On force tout le contenu interactif à passer DEVANT le fond et le grain */

header {
    display: flex; justify-content: space-between; align-items: center; padding: 30px 50px; 
    position: relative;
    z-index: 10; 
}
.hero-section {
    display: flex; flex: 1; align-items: center; justify-content: space-between;
    padding: 0 8% 50px 8%; 
    position: relative; 
    z-index: 10;
    min-height: calc(100vh - 100px);
}

/* --- RESTE DU CSS (Styles visuels inchangés) --- */

.main-logo {
    width: 55px; height: auto;
    animation: sun-spin 30s linear infinite, sun-pulse 4s ease-in-out infinite alternate;
}
@keyframes sun-spin { 100% { transform: rotate(360deg); } }
@keyframes sun-pulse {
    0% { filter: drop-shadow(0 0 5px rgba(255, 125, 37, 0.3)); }
    100% { filter: drop-shadow(0 0 15px rgba(255, 125, 37, 0.7)); scale: 1.05; }
}

.social-nav { display: flex; gap: 20px; }
.social-link {
    position: relative; display: flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; color: var(--white-off); font-size: 1.5rem; transition: color 0.3s ease; text-decoration: none;
}
.hover-star {
    position: absolute; width: 60px; z-index: -1; opacity: 0;
    transform: scale(0) rotate(-45deg); transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.social-link:hover { color: var(--orange); }
.social-link:hover .hover-star { opacity: 1; transform: scale(1) rotate(0deg); }

.content-left { max-width: 650px; }
.greeting { font-size: 2rem; font-weight: 700; margin-bottom: 10px; animation: fadeInDown 0.8s ease-out; }
h1 {
    font-size: 5rem; line-height: 1.1; font-weight: 900; margin-bottom: 50px;
    animation: fadeInLeft 1s ease-out 0.2s backwards;
}

.name-highlight {
    font-family: var(--font-name); font-weight: 700; color: var(--white-off);
    cursor: default; position: relative; font-size: 5.5rem;
    display: inline-block;
}
.name-highlight span { display: inline-block; transition: color 0.3s ease; }

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

.name-highlight:hover span {
    color: var(--orange);
    animation: floatSpace 2s ease-in-out infinite;
    text-shadow: none;
}
.name-highlight:hover span:nth-child(1) { animation-delay: 0s; }
.name-highlight:hover span:nth-child(2) { animation-delay: 0.1s; }
.name-highlight:hover span:nth-child(3) { animation-delay: 0.2s; }
.name-highlight:hover span:nth-child(4) { animation-delay: 0.3s; }
.name-highlight:hover span:nth-child(5) { animation-delay: 0.4s; }
.name-highlight:hover span:nth-child(6) { animation-delay: 0.5s; }

.portfolio-highlight {
    background: var(--orange); color: var(--white-off); padding: 5px 15px;
    display: inline-block; transform: skew(-3deg); box-shadow: none;
}

.cta-group { display: flex; gap: 25px; animation: fadeInUp 1s ease-out 0.4s backwards; }
.btn {
    padding: 15px 35px; border-radius: 50px; text-decoration: none; font-weight: 700;
    font-size: 1.1rem; display: flex; align-items: center; gap: 12px;
    transition: all 0.3s ease; position: relative; overflow: hidden; z-index: 1;
}

.btn-primary-glass {
    background-color: var(--orange); color: var(--white-off); border: none;
}
.btn-primary-glass::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 50%);
    opacity: 0; transition: opacity 0.3s ease; z-index: -1;
}
.btn-primary-glass:hover {
    background-color: var(--orange-bright); transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 20px -10px rgba(255, 125, 37, 0.5);
}
.btn-primary-glass:hover::before { opacity: 1; }

.btn-outline-glass {
    background: rgba(255, 255, 255, 0.05); color: var(--white-off);
    border: 2px solid rgba(255, 255, 255, 0.3); backdrop-filter: blur(5px);
}
.btn-outline-glass:hover {
    background: rgba(255, 255, 255, 0.15); border-color: var(--white-off);
    transform: translateY(-3px);
}

.content-right { 
    perspective: 1500px; display: flex; justify-content: center; align-items: center; 
    height: 100%; animation: floatIn 1.2s ease-out 0.5s backwards; 
}

.polaroid-frame {
    background: #fff; padding: 20px 20px 70px 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.6); width: 380px; position: relative;
    transform-style: preserve-3d; will-change: transform;
    transition: transform 0.1s ease-out, box-shadow 0.3s ease; transform: rotate(-3deg);
}

.polaroid-image {
    width: 100%; aspect-ratio: 1/1; background: #000; overflow: hidden;
    transform: translateZ(20px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.polaroid-image img { width: 100%; height: 100%; object-fit: cover; }

.polaroid-caption {
    position: absolute; bottom: 20px; left: 0; width: 100%; 
    color: #222; font-family: var(--font-polaroid); font-size: 1.4rem; 
    transform: translateZ(30px);
    text-align: left; padding-left: 30px; 
    display: flex; align-items: center; gap: 8px;
}
.static-text { white-space: nowrap; }

.typewriter-text { color: var(--orange); font-weight: bold; }
.cursor { animation: blink 1s infinite; margin-left: 2px; }

@keyframes blink { 50% { opacity: 0; } }
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInLeft { from { opacity: 0; transform: translateX(-60px); } to { opacity: 1; transform: translateX(0); } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes floatIn { from { opacity: 0; transform: scale(0.9) translateY(50px) rotate(5deg); } to { opacity: 1; transform: scale(1) translateY(0) rotate(-3deg); } }

@media (max-width: 1024px) { h1 { font-size: 4rem; } .name-highlight { font-size: 4.5rem; } .polaroid-frame { width: 300px; } }
@media (max-width: 768px) {
    header { padding: 20px 30px; }
    .hero-section { flex-direction: column; justify-content: center; text-align: center; padding-top: 0; height: auto; margin-top: 60px;}
    .content-right { display: none; }
    .content-left { max-width: 100%; }
    h1 { font-size: 3.2rem; } .name-highlight { font-size: 3.8rem; }
    .cta-group { justify-content: center; flex-direction: column; gap: 15px; }
    .btn { width: 100%; justify-content: center; }
    .gradient-orb { opacity: 0.2; filter: blur(100px); }
    .orb-orange { width: 400px; height: 400px; top: -100px; left: -100px; }
}