:root {
    --purple:       #aa32ff;
    --purple-soft:  rgba(170, 50, 255, 0.8);
    --purple-dim:   rgba(170, 50, 255, 0.3);
    --purple-glow:  rgba(170, 50, 255, 0.5);
    --bg-card:      rgba(20, 10, 40, 0.6);
    --text:         #fff;
    --text-muted:   #c9b3ff;
    --radius:       20px;
}

/* ===================== RESET & BASE ===================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    isolation: isolate;
    height: 100%;
    background: #000;
    color: var(--text);
    overflow-x: hidden;
}

/* ===================== FONTS ===================== */
@font-face {
    font-family: 'AMORIA';
    src: url('./../fonts/AMORIA.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'DM Serif Text';
    src: url('./../fonts/DMSerifText.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

body, p, li, a, button, label, input, textarea {
    font-family: 'DM Serif Text', serif;
    color: var(--text);
}

h1, h2, h3 {
    font-family: 'AMORIA', sans-serif;
}

/* ===================== BACKGROUND VIDEO ===================== */
#bg-video {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
    filter: brightness(60%);
    pointer-events: none;
}

/* ===================== HEADER & NAV (plus vivant) ===================== */
header{
    position: fixed;
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1100px;
    padding: 12px 28px;
    z-index: 100;

    background: rgba(20, 20, 30, 0.42);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    border-radius: 18px;
    border: 1px solid rgba(170,50,255,0.18);

    box-shadow:
        0 0 18px rgba(170,50,255,0.18),
        0 10px 34px rgba(0,0,0,0.35);

    transition:
        box-shadow 0.35s cubic-bezier(.16,1,.3,1),
        padding 0.35s cubic-bezier(.16,1,.3,1),
        background 0.35s cubic-bezier(.16,1,.3,1),
        transform 0.35s cubic-bezier(.16,1,.3,1);
}

/* Voile animé (vivant) */
header::before{
    content:"";
    position:absolute;
    inset:-2px;
    border-radius: 20px;
    pointer-events:none;

    background:
      radial-gradient(60% 120% at 20% 0%, rgba(170,50,255,0.22), transparent 60%),
      radial-gradient(60% 120% at 80% 100%, rgba(170,50,255,0.18), transparent 60%),
      linear-gradient(90deg, transparent, rgba(170,50,255,0.10), transparent);

    opacity: 0.9;
    filter: blur(0.2px);
    animation: headerSheen 7s ease-in-out infinite;
}

@keyframes headerSheen{
    0%,100% { transform: translateX(-6px); opacity: 0.75; }
    50%     { transform: translateX(6px);  opacity: 1; }
}

/* Micro “float” (discret) */
header{
    animation: headerFloat 5.2s ease-in-out infinite;
}
@keyframes headerFloat{
    0%,100% { translate: 0 0; }
    50%     { translate: 0 -2px; }
}

/* Etat au scroll (compact + plus net) */
header.scrolled{
    padding: 9px 22px;
    background: rgba(10, 10, 18, 0.58);
    box-shadow:
        0 0 22px rgba(170,50,255,0.22),
        0 12px 38px rgba(0,0,0,0.42);
    animation: none; /* stop float au scroll => plus stable */
}

/* Nav layout */
header nav{
    position: relative;
    display:flex;
    align-items:center;
    justify-content:space-between;
    width:100%;
    z-index:1; /* au-dessus du ::before */
}

/* Logo */
header .logo{
    display:flex;
    align-items:center;
    height:40px;
    text-decoration:none;
    position: relative;
    filter: brightness(-60%);
}

header .logo video{
    height:100%;
    width:auto;
    object-fit:contain;
    filter: drop-shadow(0 0 8px rgba(170,50,255,0.35));
    transition: transform 0.45s cubic-bezier(.16,1,.3,1), filter 0.45s cubic-bezier(.16,1,.3,1);
}

header .logo:hover video{
    transform: scale(1.10) translateY(-1px);
    filter: drop-shadow(0 0 18px rgba(170,50,255,0.65));
}

/* Liens */
header ul{
    list-style:none;
    display:flex;
    gap:36px;
}

header ul li a{
    text-decoration:none;
    color: var(--text);
    font-weight:500;
    position:relative;
    transition: color 0.35s cubic-bezier(.16,1,.3,1), transform 0.35s cubic-bezier(.16,1,.3,1);
}

/* underline “glissant” */
header ul li a::after{
    content:'';
    position:absolute;
    left:0;
    bottom:-6px;
    width:100%;
    height:2px;

    background: linear-gradient(90deg, transparent, var(--purple-soft), transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.45s cubic-bezier(.16,1,.3,1);
    filter: drop-shadow(0 0 10px rgba(170,50,255,0.35));
}

header ul li a:hover{
    color: var(--purple-soft);
    transform: translateY(-1px);
}
header ul li a:hover::after{
    transform: scaleX(1);
}

header ul li a.active{
    color: var(--purple-soft);
}
header ul li a.active::after{
    transform: scaleX(1);
}

/* Mobile: on coupe l'animation float si pas hover (plus stable) */
@media (hover: none){
    header{ animation: none; }
}

/* ===================== SECTIONS & TITLES ===================== */
.section {
    position: relative;
    z-index: 1;
    padding: 100px 20px;
}

.section-title {
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    color: var(--purple-soft);
    text-align: center;
    margin-bottom: 16px;
    text-shadow: 0 0 14px var(--purple-dim);
}

/* ===================== REVEAL ANIMATION ===================== */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(.22,1,.36,1), transform 0.7s cubic-bezier(.22,1,.36,1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===================== HERO SECTION ===================== */
.hero {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 20px;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}

.hero-eyebrow {
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    color: var(--text-muted);
    letter-spacing: 3px;
    text-transform: uppercase;
    transition-delay: 0.1s !important;
}

.hero-title {
    display: inline-flex;
    gap: 14px;
    font-size: clamp(3rem, 10vw, 7.5rem);
    line-height: 1;
    color: var(--text);
    transition-delay: 0.25s !important;
}
.hero-name{
  display: inline-block;
  transform-origin: center;
  transition:
    transform 0.45s cubic-bezier(.16,1,.3,1),
    filter 0.45s cubic-bezier(.16,1,.3,1);
  will-change: transform;
}

.hero-name:hover{
  transform: scale(1.14);
}

.hero-title:hover .hero-name:not(:hover){
  transform: scale(0.92);
  filter: blur(0.2px);
}

.hero-title .glow-text {
    color: var(--purple-soft);
    text-shadow: 0 0 30px var(--purple-glow), 0 0 60px var(--purple-dim);
    animation: pulseGlow 3s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    from { text-shadow: 0 0 20px var(--purple-glow), 0 0 50px var(--purple-dim); }
    to   { text-shadow: 0 0 40px var(--purple-glow), 0 0 80px var(--purple-dim); }
}

.hero-sub {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    color: rgba(255,255,255,0.65);
    letter-spacing: 2px;
    transition-delay: 0.4s !important;
}

.pdf-btn {
    display: inline-block;
    margin-top: 8px;
    background: linear-gradient(135deg, rgba(170,50,255,0.9), rgba(100,0,200,0.9));
    color: #fff;
    text-decoration: none;
    padding: 14px 36px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.05rem;
    box-shadow: 0 0 14px var(--purple-dim);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    transition-delay: 0.55s !important;
}

.pdf-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.18);
    transition: left 0.45s;
}

.pdf-btn:hover::before { left: 100%; }

.pdf-btn:hover {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 0 24px var(--purple-glow);
}

.pdf-btn:active { transform: scale(0.96); }

.scroll-indicator {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-indicator span {
    display: block;
    width: 24px;
    height: 40px;
    border: 2px solid rgba(255,255,255,0.35);
    border-radius: 12px;
    position: relative;
}

.scroll-indicator span::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--purple-soft);
    border-radius: 2px;
    animation: scrollDot 1.8s ease-in-out infinite;
}

@keyframes scrollDot {
    0%   { opacity: 1; top: 6px; }
    100% { opacity: 0; top: 22px; }
}

/* ===================== À PROPOS SECTION ===================== */
.apropos {
    padding-top: 120px;
    padding-bottom: 100px;
}

.apropos-title { margin-bottom: 56px; }

.apropos-split {
    max-width: 1050px;
    margin: 0 auto;
    display: flex;
    align-items: flex-start;
    gap: 64px;
}

/* gauche */
.apropos-left {
    flex: 0 0 340px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
}

.apropos-photo-wrap {
    position: relative;
    width: 320px;
    height: 380px;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(170,50,255,0.25);
    box-shadow: 0 0 30px rgba(170,50,255,0.25);
    transition: box-shadow 0.5s;
}
.apropos-photo-wrap.reveal{
    opacity: 0;
    transform: translateY(24px) scale(0.96);
    transition: opacity 0.75s cubic-bezier(.22,1,.36,1),
                transform 0.75s cubic-bezier(.22,1,.36,1),
                box-shadow 0.75s cubic-bezier(.22,1,.36,1);
}

.apropos-photo-wrap.reveal.visible{
    opacity: 1;
    transform: translateY(0) scale(1);
    box-shadow: 0 0 54px rgba(170,50,255,0.32);
}

.apropos-photo{
    transform: scale(1.03);
    filter: saturate(1.05) contrast(1.02);
    transition: transform 0.9s cubic-bezier(.22,1,.36,1),
                filter 0.9s cubic-bezier(.22,1,.36,1);
}

.apropos-photo-wrap.reveal.visible .apropos-photo{
    transform: scale(1);
    filter: saturate(1.12) contrast(1.06);
}

.apropos-photo-wrap::after{
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 45%, rgba(170,50,255,0.22), transparent 62%);
    opacity: 0;
    transition: opacity 0.8s cubic-bezier(.22,1,.36,1);
    pointer-events: none;
}

.apropos-photo-wrap.reveal.visible::after{
    opacity: 1;
}


.apropos-photo-wrap:hover {
    box-shadow: 0 0 50px rgba(170,50,255,0.45);
}

.apropos-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(0) brightness(1) saturate(1);
    transform: scale(1);
}

.apropos-silhouette {
    position: absolute;
    inset: 0;
    opacity: 0;            
    pointer-events: none;
}

.apropos-right {
    flex: 1;
    padding-top: 12px;
}

.apropos-intro {
    font-size: 1.05rem;
    line-height: 1.75;
    color: rgba(255,255,255,0.75);
    margin-bottom: 32px;
}

.apropos-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 44px;
}

.apropos-tag {
    background: var(--bg-card);
    border: 1px solid rgba(170,50,255,0.25);
    border-radius: 30px;
    padding: 8px 18px;
    font-size: 0.9rem;
}

.tag-dot{
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--purple);
    box-shadow: 0 0 6px var(--purple-glow);
    display:inline-block;
    margin-right: 8px;
    vertical-align: middle;
}


.apropos-timeline {
    position: relative;
    padding-left: 48px;
}

.apropos-timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, transparent, var(--purple-soft), transparent);
}

.apropos-tl-item { margin-bottom: 32px; }

.apropos-tl-dot{
    position:absolute;
    left: -48px;
    top: 6px;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--purple-soft);
    box-shadow: 0 0 12px var(--purple-dim), inset 0 0 8px rgba(170,50,255,0.15);
}

.apropos-tl-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    padding: 20px 24px;
    border: 1px solid rgba(170,50,255,0.18);
    box-shadow: 0 4px 18px rgba(0,0,0,0.22);
    transition: transform 0.3s, box-shadow 0.3s;
}

.apropos-tl-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 26px rgba(170,50,255,0.2);
}

.apropos-tl-year {
    display: inline-block;
    font-size: 0.78rem;
    color: var(--text-muted);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.apropos-tl-card h3 {
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 6px;
}

.apropos-tl-card p {
    font-size: 0.92rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.65);
}

/* ===================== SOFTWARES SECTION ===================== */
.softwares {
    position: relative;
    width: 92%;
    max-width: 1100px;
    overflow: hidden;
    margin: 0 auto;
    background: rgba(15, 10, 25, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 26px;
    padding: 56px 0 44px;
    box-shadow: 0 0 30px var(--purple-dim);
    border-top: 2px solid var(--purple-dim);
    transition: box-shadow 0.5s;
    z-index: 1;
}

.softwares:hover { box-shadow: 0 0 50px rgba(170,50,255,0.35); }

.marquee {
    width: 100%;
    overflow: hidden;
    padding: 40px 0;
}

.marquee-content {
    display: flex;
    align-items: center;
    gap: 56px;
    animation: marqueeScroll 55s linear infinite;
    white-space: nowrap;
    width: max-content;
}

@keyframes marqueeScroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-51%); }
}

.software-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 130px;
    transition: transform 0.3s;
    cursor: default;
}

.software-item img {
    width: 58px;
    height: 58px;
    object-fit: contain;
    filter: drop-shadow(0 0 7px var(--purple-glow));
    margin-bottom: 8px;
    transition: transform 0.3s, filter 0.3s;
}

.software-item span {
    font-size: 0.92rem;
    text-shadow: 0 0 5px var(--purple-dim);
}

.software-item:hover { transform: scale(1.08); }
.software-item:hover img { filter: drop-shadow(0 0 16px var(--purple)); }

/* ===================== PROJETS SECTION ===================== */
.projets { padding-top: 100px; padding-bottom: 80px; }

.projets-header {
    text-align: center;
    margin-bottom: 48px;
}

.projets-subtitle {
    color: rgba(255,255,255,0.48);
    font-size: 0.95rem;
    letter-spacing: 1px;
    transition-delay: 0.12s !important;
}

.carousel-wrapper {
    width: 100%;
    max-width: 780px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 22px;
}

.carousel {
    display: flex;
    transition: transform 0.5s cubic-bezier(.4,0,.2,1);
    gap: 30px;
}

.projet-card {
    min-width: 100%;
    max-width: 100%;
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 22px;
    overflow: hidden;
    border: 1px solid rgba(170,50,255,0.15);
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    position: relative;
    flex-shrink: 0;
}

.plan-badge {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 3;
    background: rgba(10,5,20,0.72);
    backdrop-filter: blur(8px);
    border: 1px solid var(--purple-dim);
    border-radius: 8px;
    padding: 6px 14px;
    font-family: 'AMORIA', sans-serif;
    font-size: 0.78rem;
    color: var(--purple-soft);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.carte-img-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    height: 320px;
}

.carte-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.carte-img-wrap:hover img { transform: scale(1.06); }

.carte-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10,5,20,0.7) 0%, transparent 50%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 22px;
    opacity: 0;
    transition: opacity 0.4s;
}

.carte-img-wrap:hover .carte-overlay { opacity: 1; }

.carte-cta {
    color: #fff;
    font-size: 1rem;
    letter-spacing: 1px;
    text-shadow: 0 2px 6px rgba(0,0,0,0.5);
}

.carte-info { padding: 24px 26px 28px; }

.carte-info h3 {
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 10px;
}

.carte-info p {
    font-size: 0.94rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.68);
}

/* Carousel Navigation */
.carousel-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 22px;
    margin-top: 34px;
}

.carousel-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--purple-dim);
    background: rgba(20,10,40,0.6);
    color: var(--text);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s, box-shadow 0.3s, transform 0.2s;
}

.carousel-btn:hover {
    background: rgba(170,50,255,0.25);
    box-shadow: 0 0 14px var(--purple-dim);
    transform: scale(1.08);
}

.carousel-btn:active { transform: scale(0.92); }

.carousel-dots { display: flex; gap: 10px; }

.carousel-dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
}

.carousel-dots .dot.active {
    background: var(--purple-soft);
    transform: scale(1.25);
    box-shadow: 0 0 8px var(--purple-glow);
}

.carousel-dots .dot:hover { background: rgba(170,50,255,0.5); }

/* ===================== CONTACT SECTION ===================== */
.contact-section {
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.contact-split {
    display: flex;
    gap: 40px;
    align-items: stretch;
    margin-top: 48px;
}

.contact-left {
    flex: 1;
    min-width: 0;
    transition-delay: 0.1s !important;
}

.contact-card {
    position: relative;
    background: var(--bg-card);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-radius: 24px;
    padding: 40px 32px;
    height: 100%;
    box-shadow: 0 0 28px var(--purple-dim);
    overflow: hidden;
    border: 1px solid rgba(170,50,255,0.18);
    transition: box-shadow 0.4s;
}

.contact-card:hover { box-shadow: 0 0 42px var(--purple-glow); }

.card-glow {
    position: absolute;
    top: -60%;
    left: -60%;
    width: 220%;
    height: 220%;
    background: conic-gradient(from 0deg, #8e44ff, #6c2bff, #a678ff, #8e44ff);
    filter: blur(65px);
    opacity: 0.2;
    animation: rotateGlow 7s linear infinite;
    z-index: 0;
}

@keyframes rotateGlow { to { transform: rotate(360deg); } }

.contact-info { position: relative; z-index: 1; }

.contact-info h3 {
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 12px;
}

.contact-info > p {
    font-size: 0.97rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.6;
    margin-bottom: 28px;
}

.contact-profile {
    display: flex;
    justify-content: center;
    margin-bottom: 18px;
}

.contact-avatar {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 1px solid rgba(170,50,255,0.35);
    box-shadow: 0 0 18px rgba(170,50,255,0.22), 0 0 38px rgba(170,50,255,0.14);
    filter: saturate(1.05) contrast(1.02);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.contact-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 0 26px rgba(170,50,255,0.35), 0 0 60px rgba(170,50,255,0.18);
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.contact-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(90deg, rgba(142,68,255,0.75), rgba(166,120,255,0.55));
    border: none;
    border-radius: 12px;
    padding: 12px 18px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.96rem;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 0 10px rgba(150,80,255,0.2);
}

.contact-btn img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    filter: brightness(1.3);
}

.contact-btn:hover {
    transform: scale(1.04);
    box-shadow: 0 0 22px var(--purple-glow);
}

.contact-btn:active { transform: scale(0.97); }

/* Contact Form */
.contact-right {
    flex: 1;
    min-width: 0;
    transition-delay: 0.22s !important;
}

.email-form-container {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 24px;
    padding: 40px 32px;
    height: 100%;
    box-shadow: 0 0 28px var(--purple-dim);
    border: 1px solid rgba(170,50,255,0.18);
}

.email-form-container h3 {
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 24px;
}

.email-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.email-form label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: -8px;
}

.email-form input,
.email-form textarea {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(170,50,255,0.35);
    border-radius: 10px;
    padding: 12px 16px;
    color: #fff;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.email-form input::placeholder,
.email-form textarea::placeholder { color: rgba(255,255,255,0.3); }

.email-form input:focus,
.email-form textarea:focus {
    border-color: rgba(200,120,255,0.85);
    box-shadow: 0 0 14px rgba(200,120,255,0.4);
}

.email-form textarea { resize: vertical; }

.email-btn {
    background: linear-gradient(135deg, rgba(170,50,255,0.9), rgba(100,0,200,0.9));
    border: none;
    border-radius: 50px;
    color: #fff;
    padding: 13px 28px;
    font-size: 1.05rem;
    font-family: 'DM Serif Text', serif;
    cursor: pointer;
    align-self: flex-start;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 0 12px var(--purple-dim);
}

.email-btn:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 0 22px var(--purple-glow);
}

.email-btn:active { transform: scale(0.96); }

/* ===================== FOOTER ===================== */
footer {
    position: relative;
    z-index: 1;
    background: rgba(10,10,20,0.82);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 36px 20px 28px;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}

.footer-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
}

.footer-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(170,50,255,0.85), rgba(100,0,200,0.85));
    box-shadow: 0 0 10px var(--purple-dim);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
}

.footer-btn img {
    width: 22px;
    height: 22px;
    filter: brightness(1.2);
    transition: transform 0.3s;
}

.footer-btn:hover {
    transform: scale(1.12);
    box-shadow: 0 0 20px var(--purple-glow);
}

.footer-btn:hover img { transform: scale(1.1); }

footer p {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.4);
}

/* ===================== MEDIA QUERIES ===================== */
@media (max-width: 860px) {
    .apropos-split {
        flex-direction: column;
        align-items: center;
        gap: 48px;
    }

    .apropos-left { flex: none; }

    .apropos-right {
        width: 100%;
        max-width: 560px;
    }

    .contact-split { flex-direction: column; }
    .carousel-wrapper { max-width: 95vw; }
}

@media (max-width: 680px) {
    header {
        top: 0;
        width: 100%;
        border-radius: 0 0 16px 16px;
        padding: 10px 18px;
    }

    header nav {
        flex-direction: column;
        gap: 8px;
    }

    header ul {
        gap: 20px;
        justify-content: center;
    }

    header .logo { height: 34px; }

    .hero { padding-top: 80px; }

    .hero-title { font-size: clamp(2.4rem, 12vw, 4rem); }

    .section { padding: 70px 18px; }

    .apropos {
        padding-top: 95px;
        padding-bottom: 70px;
    }

    .apropos-title { margin-bottom: 34px; }

    .apropos-split {
        flex-direction: column;
        align-items: center;
        gap: 34px;
    }

    .apropos-left {
        flex: none;
        width: 100%;
        gap: 14px;
    }

    .apropos-photo-wrap {
        width: min(86vw, 300px);
        height: min(98vw, 360px);
        border-radius: 20px;
    }

    .apropos-photo,
    .apropos-silhouette { border-radius: 20px; }

    .apropos-right {
        width: 100%;
        max-width: 560px;
        padding-top: 0;
    }

    .apropos-intro {
        font-size: 0.98rem;
        line-height: 1.7;
        margin-bottom: 22px;
    }

    .apropos-tags {
        gap: 8px;
        margin-bottom: 28px;
        justify-content: center;
    }

    .apropos-tag {
        font-size: 0.88rem;
        padding: 7px 14px;
    }

    .apropos-timeline { padding-left: 36px; }

    .apropos-timeline::before { left: 14px; }

    .apropos-tl-dot {
        left: -36px;
        width: 32px;
        height: 32px;
    }

    .apropos-tl-card {
        padding: 16px;
        border-radius: 14px;
    }

    .apropos-tl-card h3 { font-size: 1.02rem; }
    .apropos-tl-card p  { font-size: 0.9rem; }

    .softwares {
        width: 96%;
        border-radius: 18px;
        padding: 42px 0 34px;
    }

    .marquee-content {
        gap: 34px;
        animation-duration: 28s;
    }

    .software-item { min-width: 90px; }

    .software-item img {
        width: 44px;
        height: 44px;
    }

    .carte-img-wrap { height: 240px; }

    .contact-card,
    .email-form-container { padding: 28px 22px; }
}

@media (max-width: 380px) {
    header ul { gap: 14px; }
    header ul li a { font-size: 0.85rem; }
    .hero-title { font-size: 2rem; }

    .apropos-photo-wrap {
        width: 220px;
        height: 270px;
    }
}

@media (hover: none) {
    .apropos-photo-wrap:hover {
        box-shadow: 0 0 30px rgba(170,50,255,0.25);
    }
}

/* ===================== GALERIE PAGE ===================== */
.galerie-page{
  padding-top: 120px;
  max-width: 1100px;
  margin: 0 auto;
}

.galerie-top{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 18px 0 34px;
}

.galerie-desc{
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
}

.galerie-back{
  padding: 12px 20px;
  font-size: 0.95rem;
}

.galerie-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.galerie-item{
  border: 1px solid rgba(170,50,255,0.20);
  background: rgba(20,10,40,0.35);
  border-radius: 18px;
  overflow: hidden;
  padding: 0;
  cursor: pointer;
  box-shadow: 0 0 18px rgba(170,50,255,0.10);
  transition: transform 0.35s cubic-bezier(.16,1,.3,1), box-shadow 0.35s cubic-bezier(.16,1,.3,1);
}

.galerie-item:hover{
  transform: translateY(-3px) scale(1.01);
  box-shadow: 0 0 32px rgba(170,50,255,0.22);
}

.galerie-item img{
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}

/* Lightbox */
.lightbox{
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 999;
  padding: 28px;
}

.lightbox.open{ display: grid; }

.lightbox-img{
  max-width: min(100%, 1100px);
  max-height: 82vh;
  border-radius: 18px;
  border: 1px solid rgba(170,50,255,0.30);
  box-shadow: 0 0 46px rgba(170,50,255,0.25);
}

.lightbox-close{
  position: absolute;
  top: 18px;
  right: 18px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(170,50,255,0.25);
  background: rgba(20,10,40,0.6);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: 0 0 18px rgba(170,50,255,0.18);
  transition: transform 0.25s cubic-bezier(.16,1,.3,1);
}

.lightbox-close:hover{ transform: scale(1.08); }

/* Responsive */
@media (max-width: 900px){
  .galerie-grid{ grid-template-columns: repeat(2, 1fr); }
  .galerie-item img{ height: 240px; }
}

@media (max-width: 560px){
  .galerie-top{ flex-direction: column; align-items: flex-start; }
  .galerie-grid{ grid-template-columns: 1fr; }
  .galerie-item img{ height: 240px; }
}


/* ====== SECRET PORTAL ====== */
.secret-portal{
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at center,
    rgba(170,50,255,0.12),
    rgba(0,0,0,0.85));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
  z-index: 9999;
}

.secret-portal.show{
  opacity: 1;
  pointer-events: auto;
}

.portal-frame{
  position: relative;
  width: min(320px, 90vw);
  padding: 28px 24px 24px;
  background: rgba(20,10,40,0.75);
  border-radius: 22px;
  border: 1px solid rgba(170,50,255,0.35);
  box-shadow:
    0 0 30px rgba(170,50,255,0.35),
    inset 0 0 20px rgba(170,50,255,0.12);
  animation: portalIn 0.6s cubic-bezier(.16,1,.3,1);
}

.portal-frame::before{
  content:"";
  position:absolute;
  inset:-40%;
  background:
    radial-gradient(circle at 30% 30%, rgba(170,50,255,0.22), transparent 45%),
    radial-gradient(circle at 70% 60%, rgba(120,80,255,0.18), transparent 50%);
  filter: blur(22px);
  pointer-events:none;
}

.portal-title{
  display:block;
  text-align:center;
  font-family:'AMORIA', sans-serif;
  letter-spacing:4px;
  font-size:0.85rem;
  color:var(--purple-soft);
  margin-bottom:14px;
}

#secretInput{
  width:100%;
  background: rgba(255,255,255,0.06);
  border:1px solid rgba(170,50,255,0.45);
  border-radius:999px;
  padding:12px 18px;
  text-align:center;
  color:#fff;
  font-size:1rem;
  letter-spacing:2px;
  outline:none;
  box-shadow: 0 0 12px rgba(170,50,255,0.25);
  transition:
    border-color 0.3s,
    box-shadow 0.3s,
    background 0.3s;
}

#secretInput::placeholder{
  color: rgba(255,255,255,0.4);
}

#secretInput:focus{
  border-color: var(--purple-soft);
  box-shadow: 0 0 20px var(--purple-glow);
  background: rgba(255,255,255,0.1);
}

@keyframes portalIn{
  from{
    transform: scale(0.85) translateY(20px);
    opacity:0;
  }
  to{
    transform: scale(1) translateY(0);
    opacity:1;
  }
}

/* glyph */
.footer-secret{
  display:flex;
  justify-content:center;
  margin-top:10px;
}

#secretGlyph{
  font-size:0.85rem;
  letter-spacing:6px;
  color:rgba(255,255,255,0.28);
  cursor:pointer;
  transition:color .35s, text-shadow .35s, transform .35s;
}

#secretGlyph:hover{
  color:var(--purple-soft);
  text-shadow:0 0 12px var(--purple-glow);
  transform:scale(1.1);
}

/* ===== FIX MOBILE : centrage + safe-area ===== */
@media (max-width: 680px) {

  /* Safe-area globale (encoches) */
  body{
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }

  /* Header : centrage "layout" (pas de transform) */
  header{
    top: 0;
    left: 0;
    right: 0;

    width: auto;                 /* important */
    margin: 0 auto;

    transform: none !important;
    translate: 0 0 !important;
    animation: none !important;

    /* garde ta DA */
    border-radius: 0 0 16px 16px;
  }

  header::before{
    animation: none !important;  /* évite le drift visuel */
  }

  /* Le contenu : padding safe-area + centrage garanti */
  .hero,
  .section{
    width: 100%;
    padding-left: calc(20px + env(safe-area-inset-left));
    padding-right: calc(20px + env(safe-area-inset-right));
  }

  /* Le bloc hero au centre (même si un navigateur “décale” le rendu) */
  .hero-content{
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
  }
}

html, body { width: 100%; overflow-x: clip; }


