/* ============================================================
   KILIAN SARROCA BONNAFÉ — Portfolio Professionnel
   Design : Éditorial raffiné — sombre, sobre, élégant
   Polices : Cormorant Garamond (titres) + DM Sans (corps)
   ============================================================ */

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

/* === VARIABLES === */

/* ── Cross-browser compatibility patch ── */
html { -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; }
img, video { max-width: 100%; height: auto; }
button, input, select, textarea { font-family: inherit; }
a { -webkit-tap-highlight-color: transparent; }
* { -webkit-box-sizing: border-box; box-sizing: border-box; }

:root {
    /* Couleurs */
    --ink:        #0f1117;
    --ink-soft:   #1c2030;
    --ink-card:   #161b27;
    --rule:       rgba(255,255,255,0.07);
    --rule-hover: rgba(255,255,255,0.14);
    --white:      #f4f4f2;
    --muted:      #7a7f94;
    --muted-lt:   #a0a5b8;
    --gold:       #c8a86b;
    --gold-pale:  rgba(200,168,107,0.12);
    --gold-glow:  rgba(200,168,107,0.25);

    /* Typographie */
    --font-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-body:    'DM Sans', 'Helvetica Neue', Arial, sans-serif;

    /* Espace & Rayon */
    --gap:     clamp(1.5rem, 3vw, 2.5rem);
    --r:       6px;
    --r-lg:    12px;

    /* Transition */
    --ease:    0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

/* === BASE === */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.65;
    color: var(--white);
    background-color: var(--ink);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Grain de fond subtil */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 0;
    opacity: 0.5;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: inherit; text-decoration: none; }
ul  { list-style: none; }

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 clamp(1.25rem, 4vw, 3rem);
    width: 100%;
    position: relative;
    z-index: 1;
}

/* Focus accessible */
:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 4px;
    border-radius: var(--r);
}

/* ============================================================
   TYPOGRAPHIE
   ============================================================ */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.display-name {
    font-family: var(--font-display);
    font-size: clamp(3rem, 8vw, 6.5rem);
    font-weight: 600;
    line-height: 1;
    letter-spacing: -0.03em;
    color: var(--white);
}

.display-name em {
    font-style: italic;
    color: var(--gold);
}

.section-label {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gold);
    display: block;
    margin-bottom: 1rem;
}

.section-heading {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 600;
    color: var(--white);
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.section-heading em {
    font-style: italic;
    color: var(--gold);
}

.body-text {
    font-size: 0.975rem;
    color: var(--muted-lt);
    line-height: 1.8;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: background var(--ease), border-color var(--ease);
}

.navbar.scrolled {
    background: rgba(15, 17, 23, 0.92);
    -webkit-backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--rule);
}

.nav-container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 clamp(1.25rem, 4vw, 3rem);
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.logo {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--white);
    letter-spacing: 0.02em;
    transition: color var(--ease);
}

.logo .dot {
    color: var(--gold);
}

.logo:hover { color: var(--gold); }

/* Liens nav */
.nav-links {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
    transition: color var(--ease);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width var(--ease);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--white);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* CTA nav */
.nav-cta {
    font-size: 0.78rem !important;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gold) !important;
    border: 1px solid rgba(200,168,107,0.4);
    padding: 0.45rem 1rem;
    border-radius: var(--r);
    transition: all var(--ease) !important;
}

.nav-cta::after { display: none !important; }

.nav-cta:hover {
    background: var(--gold-pale);
    border-color: var(--gold) !important;
    color: var(--gold) !important;
}

/* Burger */
.burger {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.burger span {
    display: block;
    width: 22px;
    height: 1.5px;
    background: var(--white);
    border-radius: 1px;
    transition: all var(--ease);
    transform-origin: center;
}

.burger.open span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger.open span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

/* ============================================================
   BOUTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.75rem 1.6rem;
    border-radius: var(--r);
    border: none;
    cursor: pointer;
    transition: all var(--ease);
    text-decoration: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn-gold {
    background: var(--gold);
    color: var(--ink);
    font-weight: 600;
}

.btn-gold:hover {
    background: #d9b87a;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px var(--gold-glow);
    color: var(--ink);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 1px solid var(--rule-hover);
}

.btn-outline:hover {
    border-color: var(--gold);
    color: var(--gold);
    background: var(--gold-pale);
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    color: var(--muted);
    border: 1px solid var(--rule);
    font-size: 0.78rem;
}

.btn-ghost:hover {
    color: var(--white);
    border-color: var(--rule-hover);
    background: rgba(255,255,255,0.04);
}

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
[data-reveal] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1),
                transform 0.7s cubic-bezier(0.4,0,0.2,1);
}

[data-reveal].revealed { opacity: 1; transform: none; }

[data-delay="1"] { transition-delay: 0.08s; }
[data-delay="2"] { transition-delay: 0.16s; }
[data-delay="3"] { transition-delay: 0.24s; }
[data-delay="4"] { transition-delay: 0.32s; }
[data-delay="5"] { transition-delay: 0.40s; }

/* ============================================================
   PAGE ACCUEIL — HERO
   ============================================================ */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 0 0 5rem;
    position: relative;
    overflow: hidden;
}

/* Dégradé radial subtil */
.hero::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -5%;
    width: 60vw;
    height: 60vw;
    max-width: 800px;
    max-height: 800px;
    background: radial-gradient(circle, rgba(200,168,107,0.06) 0%, transparent 65%);
    pointer-events: none;
    z-index: 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: var(--gap);
    align-items: flex-end;
}

.hero-left {
    position: relative;
    z-index: 1;
}

.hero-eyebrow {
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.hero-eyebrow::before {
    content: '';
    display: inline-block;
    width: 28px;
    height: 1px;
    background: var(--gold);
}

.hero-title {
    margin-bottom: 2rem;
}

.hero-subtitle {
    font-size: clamp(0.9rem, 1.8vw, 1.05rem);
    color: var(--muted-lt);
    line-height: 1.75;
    max-width: 480px;
    margin-bottom: 3rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 3rem;
}

.hero-socials {
    display: flex;
    align-items: center;
    gap: 1.4rem;
}

.hero-socials a {
    color: var(--muted);
    font-size: 1rem;
    transition: color var(--ease), transform var(--ease);
    display: flex;
    align-items: center;
}

.hero-socials a:hover {
    color: var(--gold);
    transform: translateY(-2px);
}

/* Photo */
.hero-right {
    position: relative;
    z-index: 1;
    align-self: flex-end;
}

.hero-photo-wrap {
    position: relative;
    width: clamp(200px, 22vw, 300px);
}

.hero-photo-wrap::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: var(--r-lg);
    background: linear-gradient(145deg, rgba(200,168,107,0.3), transparent 50%);
    z-index: -1;
}

.hero-photo {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    object-position: center top;
    border-radius: var(--r-lg);
    filter: grayscale(20%);
    display: block;
}

/* Ligne de séparation hero */
.hero-divider {
    width: 100%;
    height: 1px;
    background: var(--rule);
    margin: 4rem 0 0;
    position: relative;
    z-index: 1;
}

/* Stats rapides */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, auto);
    justify-content: start;
    gap: 3rem;
    padding-top: 2.5rem;
    position: relative;
    z-index: 1;
}

.stat-num {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    color: var(--white);
    line-height: 1;
    margin-bottom: 0.3rem;
}

.stat-num span {
    color: var(--gold);
}

.stat-label {
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}

/* ============================================================
   SECTION À PROPOS (index)
   ============================================================ */
.about-section {
    padding: clamp(4rem, 8vw, 7rem) 0;
    border-top: 1px solid var(--rule);
}

.about-layout {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 5rem;
    align-items: start;
}

.about-sticky {
    position: sticky;
    top: 100px;
}

.about-body p {
    font-size: 1.05rem;
    color: var(--muted-lt);
    line-height: 1.85;
    margin-bottom: 1.6rem;
}

.about-body p:last-child { margin-bottom: 0; }

.detail-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    overflow: hidden;
    margin-top: 2.5rem;
}

.detail-item {
    background: var(--ink-card);
    padding: 1.4rem 1.6rem;
    transition: background var(--ease);
}

.detail-item:hover { background: var(--ink-soft); }

.detail-item .detail-label {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.4rem;
}

.detail-item .detail-value {
    font-size: 0.9rem;
    color: var(--white);
    font-weight: 500;
}

/* ============================================================
   PAGE HERO (sous-pages)
   ============================================================ */
.page-header {
    padding: 8rem 0 3.5rem;
    border-bottom: 1px solid var(--rule);
    position: relative;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 50%;
    height: 100%;
    background: radial-gradient(ellipse at right center, rgba(200,168,107,0.04), transparent 70%);
    pointer-events: none;
}

/* ============================================================
   PAGE COMPÉTENCES
   ============================================================ */
.skills-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

.skills-category-block {
    margin-bottom: clamp(3rem, 6vw, 5rem);
}

.skills-category-block:last-child { margin-bottom: 0; }

.skills-category-title {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 500;
    color: var(--white);
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--rule);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.skills-category-title i {
    color: var(--gold);
    font-size: 1rem;
}

.skills-table {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    overflow: hidden;
}

.skill-row {
    background: var(--ink-card);
    padding: 1.1rem 1.6rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    transition: background var(--ease);
}

.skill-row:hover { background: var(--ink-soft); }

/* .skill-header removed */

.skill-name {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.skill-name i {
    color: var(--gold);
    font-size: 0.85rem;
    width: 1rem;
    text-align: center;
}

.skill-pct {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    color: var(--gold);
}

.skill-bar {
    height: 2px;
    background: var(--rule);
    border-radius: 1px;
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold), #e8c88a);
    border-radius: 1px;
    width: 0;
    transition: width 1.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Soft skills en badges */
.soft-skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.soft-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.1rem;
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: 100px;
    font-size: 0.85rem;
    color: var(--muted-lt);
    transition: all var(--ease);
}

.soft-badge i {
    color: var(--gold);
    font-size: 0.8rem;
}

.soft-badge:hover {
    border-color: var(--gold);
    color: var(--white);
    background: var(--gold-pale);
}

/* ============================================================
   PAGE PROJETS
   ============================================================ */
.projects-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

.project-list {
    display: grid;
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    overflow: hidden;
}

.project-item {
    background: var(--ink-card);
    padding: clamp(1.5rem, 3vw, 2.5rem);
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 2rem;
    align-items: start;
    transition: background var(--ease);
    text-decoration: none;
    position: relative;
}

.project-item::after {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 2px;
    background: var(--gold);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform var(--ease);
}

.project-item:hover { background: var(--ink-soft); }
.project-item:hover::after { transform: scaleY(1); }

.project-num {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--muted);
    padding-top: 0.2rem;
    min-width: 2.5rem;
    font-style: italic;
}

.project-info h3 {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    font-weight: 600;
    color: var(--white);
    margin-bottom: 0.5rem;
    transition: color var(--ease);
}

.project-item:hover .project-info h3 { color: var(--gold); }

.project-info p {
    font-size: 0.9rem;
    color: var(--muted);
    line-height: 1.65;
    max-width: 580px;
    margin-bottom: 1.2rem;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.project-tag {
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--rule);
    padding: 0.25rem 0.65rem;
    border-radius: 3px;
}

.project-arrow {
    color: var(--muted);
    font-size: 0.9rem;
    transition: all var(--ease);
    padding-top: 0.4rem;
}

.project-item:hover .project-arrow {
    color: var(--gold);
    transform: translate(3px, -3px);
}

/* ============================================================
   PAGE CONTACT
   ============================================================ */
.contact-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 5rem;
    align-items: start;
}

.contact-sidebar-sticky {
    position: sticky;
    top: 100px;
}

.contact-sidebar p {
    font-size: 1rem;
    color: var(--muted-lt);
    line-height: 1.8;
    margin-bottom: 2.5rem;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    overflow: hidden;
    margin-bottom: 2rem;
}

.contact-link-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.1rem 1.4rem;
    background: var(--ink-card);
    color: var(--muted-lt);
    text-decoration: none;
    transition: all var(--ease);
    font-size: 0.9rem;
}

.contact-link-item i {
    color: var(--gold);
    font-size: 0.9rem;
    width: 1.2rem;
    text-align: center;
    flex-shrink: 0;
}

.contact-link-item span {
    flex: 1;
}

.contact-link-item .link-arrow {
    color: var(--muted);
    font-size: 0.7rem;
    transition: all var(--ease);
}

.contact-link-item:hover {
    background: var(--ink-soft);
    color: var(--white);
}

.contact-link-item:hover .link-arrow {
    color: var(--gold);
    transform: translate(2px, -2px);
}

/* Formulaire */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.form-group label {
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}

.form-group input,
.form-group textarea {
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: var(--r);
    padding: 0.85rem 1rem;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: all var(--ease);
    -webkit-appearance: none;
    appearance: none;
}

.form-group textarea {
    resize: vertical;
    min-height: 140px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--muted);
    opacity: 0.55;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: rgba(200,168,107,0.5);
    background: var(--ink-soft);
    box-shadow: 0 0 0 3px var(--gold-pale);
}

.form-note {
    font-size: 0.78rem;
    color: var(--muted);
    margin-top: 0.5rem;
}

.form-success {
    display: none;
    text-align: center;
    padding: 3rem 2rem;
    border: 1px solid rgba(200,168,107,0.3);
    border-radius: var(--r-lg);
    background: var(--gold-pale);
}

.form-success i {
    font-size: 2rem;
    color: var(--gold);
    margin-bottom: 1rem;
    display: block;
}

.form-success p {
    color: var(--muted-lt);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
    border-top: 1px solid var(--rule);
    padding: 2rem 0;
    margin-top: auto;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-copy {
    font-size: 0.78rem;
    color: var(--muted);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    font-size: 0.78rem;
    color: var(--muted);
    transition: color var(--ease);
}

.footer-links a:hover { color: var(--gold); }

/* ============================================================
   BACK TO TOP
   ============================================================ */
.back-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--ink-card);
    border: 1px solid var(--rule);
    color: var(--muted);
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(8px);
    transition: all var(--ease);
    z-index: 500;
    text-decoration: none;
}

.back-top.visible {
    opacity: 1;
    transform: none;
}

.back-top:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--ink);
}

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--ink); }
::-webkit-scrollbar-thumb { background: rgba(200,168,107,0.3); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .about-layout { grid-template-columns: 1fr; gap: 3rem; }
    .about-sticky { position: static; }
    .contact-layout { grid-template-columns: 1fr; gap: 3rem; }
    .contact-sidebar-sticky { position: static; }
    .hero-grid { grid-template-columns: 1fr; }
    .hero-right { display: none; }
    .hero { justify-content: center; padding: 8rem 0 4rem; }
    .hero-stats { grid-template-columns: repeat(3, 1fr); justify-content: stretch; }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 68px; left: 0;
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        background: rgba(15, 17, 23, 0.98);
        -webkit-backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--rule);
        padding: 1.5rem clamp(1.25rem, 4vw, 3rem) 2rem;
        transform: translateY(-110%);
        opacity: 0;
        pointer-events: none;
        transition: all var(--ease);
        z-index: 999;
    }

    .nav-links.open {
        transform: none;
        opacity: 1;
        pointer-events: all;
    }

    .nav-links li { width: 100%; }

    .nav-links a {
        display: block;
        padding: 0.85rem 0;
        font-size: 1rem;
        border-bottom: 1px solid var(--rule);
    }

    .nav-links li:last-child a { border: none; }
    .nav-cta { border: none !important; padding: 0.85rem 0 !important; }

    .burger { display: flex; }

    .hero-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }

    .detail-list { grid-template-columns: 1fr; }

    .form-row { grid-template-columns: 1fr; }

    .project-item { grid-template-columns: 1fr; }
    .project-num { display: none; }
    .project-arrow { position: absolute; top: 1.5rem; right: 1.5rem; }

    .footer-inner { flex-direction: column; align-items: flex-start; }

    .hero-stats { grid-template-columns: repeat(2, 1fr); }
    .hero-stats .stat-item:last-child { grid-column: 1 / -1; }
}

@media (max-width: 480px) {
    .hero-actions .btn { width: 100%; justify-content: center; }
    .hero-actions { flex-direction: column; }
    .skills-table { grid-template-columns: 1fr; }
}

@media print {
    .navbar, .burger, .back-top, body::before { display: none !important; }
    body { background: #fff; color: #000; }
    * { color: #000 !important; }
}

/* ============================================================
   NOUVEAUX COMPOSANTS — v2
   ============================================================ */

/* ── Transition de page ── */
#page-overlay {
    position: fixed;
    inset: 0;
    background: var(--ink);
    z-index: 9998;
    pointer-events: none;
    opacity: 1;
    transition: opacity 0.35s cubic-bezier(0.4,0,0.2,1);
}

#page-overlay.out { opacity: 0; }

/* ── Barre de progression scroll ── */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: left;
    z-index: 2000;
    pointer-events: none;
    box-shadow: 0 0 6px var(--gold-glow);
}

/* ── Favicon SVG inline (injection par JS si besoin) ── */

/* ============================================================
   PAGE CERTIFICATIONS
   ============================================================ */
.cert-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

.cert-intro {
    max-width: 560px;
    margin-bottom: 3.5rem;
}

.cert-intro p {
    font-size: 1rem;
    color: var(--muted-lt);
    line-height: 1.8;
    margin-top: 1rem;
}

/* Grille de certifications */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3.5rem;
}

.cert-card {
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    transition: all var(--ease);
    position: relative;
    overflow: hidden;
}

.cert-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gold), transparent);
    opacity: 0;
    transition: opacity var(--ease);
}

.cert-card:hover {
    border-color: var(--rule-hover);
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.3);
}

.cert-card:hover::before { opacity: 1; }

.cert-card.obtained {
    border-color: rgba(200,168,107,0.3);
}

.cert-card.obtained::before { opacity: 1; }

.cert-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.cert-logo {
    width: 48px;
    height: 48px;
    background: var(--ink-soft);
    border-radius: var(--r);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--gold);
    flex-shrink: 0;
}

.cert-status {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.25rem 0.7rem;
    border-radius: 100px;
    flex-shrink: 0;
}

.cert-status.obtained {
    background: rgba(200,168,107,0.15);
    color: var(--gold);
    border: 1px solid rgba(200,168,107,0.3);
}

.cert-status.in-progress {
    background: rgba(99,179,237,0.1);
    color: #63b3ed;
    border: 1px solid rgba(99,179,237,0.25);
}

.cert-status.planned {
    background: rgba(160,165,184,0.08);
    color: var(--muted);
    border: 1px solid var(--rule);
}

.cert-card h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--white);
    line-height: 1.3;
}

.cert-card .cert-issuer {
    font-size: 0.82rem;
    color: var(--muted);
    margin-top: 0.2rem;
}

.cert-card p {
    font-size: 0.88rem;
    color: var(--muted-lt);
    line-height: 1.65;
}

.cert-date {
    font-size: 0.75rem;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--rule);
}

.cert-date i { color: var(--gold); font-size: 0.7rem; }

/* Bloc "comment ça marche" */
.cert-placeholder-note {
    background: var(--ink-card);
    border: 1px dashed rgba(200,168,107,0.25);
    border-radius: var(--r-lg);
    padding: 2rem 2.5rem;
    max-width: 640px;
}

.cert-placeholder-note h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--gold);
    margin-bottom: 1rem;
}

.cert-placeholder-note ol {
    list-style: decimal;
    padding-left: 1.5rem;
    color: var(--muted-lt);
    font-size: 0.9rem;
    line-height: 2;
}

.cert-placeholder-note ol li { padding-left: 0.3rem; }

.cert-placeholder-note code {
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    background: rgba(200,168,107,0.08);
    color: var(--gold);
    padding: 0.1rem 0.4rem;
    border-radius: 3px;
}

/* ============================================================
   PAGE VEILLE TECHNOLOGIQUE
   ============================================================ */
.veille-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

/* Barre de filtres */
.veille-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 3rem;
}

.filter-btn {
    background: transparent;
    border: 1px solid var(--rule);
    color: var(--muted);
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.5rem 1.1rem;
    border-radius: 100px;
    cursor: pointer;
    transition: all var(--ease);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--gold-pale);
    border-color: var(--gold);
    color: var(--gold);
}

/* Grille d'articles */
.veille-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.veille-card {
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all var(--ease);
    position: relative;
}

.veille-card:hover {
    border-color: var(--rule-hover);
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.3);
}

/* Bandeau couleur catégorie */
.veille-card-band {
    height: 3px;
    width: 100%;
}

.veille-card-band.cyber    { background: linear-gradient(90deg, #63b3ed, #4299e1); }
.veille-card-band.reseau   { background: linear-gradient(90deg, var(--gold), #e8c88a); }
.veille-card-band.systeme  { background: linear-gradient(90deg, #68d391, #48bb78); }
.veille-card-band.securite { background: linear-gradient(90deg, #fc8181, #f56565); }

.veille-card-body {
    padding: 1.6rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.veille-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.veille-cat-badge {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.2rem 0.65rem;
    border-radius: 100px;
}

.veille-cat-badge.cyber    { background: rgba(99,179,237,0.12);  color: #63b3ed;  border: 1px solid rgba(99,179,237,0.25); }
.veille-cat-badge.reseau   { background: var(--gold-pale);        color: var(--gold);  border: 1px solid rgba(200,168,107,0.25); }
.veille-cat-badge.systeme  { background: rgba(104,211,145,0.1);   color: #68d391;  border: 1px solid rgba(104,211,145,0.2); }
.veille-cat-badge.securite { background: rgba(252,129,129,0.1);   color: #fc8181;  border: 1px solid rgba(252,129,129,0.2); }

.veille-date {
    font-size: 0.75rem;
    color: var(--muted);
}

.veille-card h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--white);
    line-height: 1.35;
    margin-bottom: 0.75rem;
    transition: color var(--ease);
}

.veille-card:hover h3 { color: var(--gold); }

.veille-card p {
    font-size: 0.88rem;
    color: var(--muted-lt);
    line-height: 1.7;
    flex: 1;
    margin-bottom: 1.4rem;
}

.veille-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid var(--rule);
}

.veille-source {
    font-size: 0.75rem;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.veille-source i { font-size: 0.7rem; }

.veille-link {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--gold);
    display: flex;
    align-items: center;
    gap: 0.3rem;
    letter-spacing: 0.05em;
    transition: gap var(--ease);
    text-decoration: none;
}

.veille-card:hover .veille-link { gap: 0.6rem; }

/* Encadré "Comment fonctionne ma veille" */
.veille-method {
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: var(--r-lg);
    padding: 2.5rem;
    margin-top: 4rem;
}

.veille-method-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.veille-method-item {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.veille-method-item i {
    font-size: 1.2rem;
    color: var(--gold);
    margin-bottom: 0.3rem;
}

.veille-method-item h4 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
}

.veille-method-item p {
    font-size: 0.84rem;
    color: var(--muted);
    line-height: 1.6;
}

/* ============================================================
   RESPONSIVE ADDITIONS
   ============================================================ */
@media (max-width: 768px) {
    .cert-grid       { grid-template-columns: 1fr; }
    .veille-grid     { grid-template-columns: 1fr; }
    .veille-filters  { gap: 0.4rem; }
    .filter-btn      { font-size: 0.72rem; padding: 0.4rem 0.9rem; }
    .veille-method-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .veille-method-grid { grid-template-columns: 1fr; }
    .cert-placeholder-note { padding: 1.5rem; }
}

/* ============================================================
   PAGE EXPÉRIENCES
   ============================================================ */
.xp-body {
    padding: clamp(3rem, 6vw, 5rem) 0;
}

/* Timeline */
.xp-timeline {
    position: relative;
    padding-left: 2rem;
}

.xp-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom, var(--gold), rgba(200,168,107,0.1));
}

.xp-item {
    position: relative;
    margin-bottom: 3.5rem;
    padding-bottom: 3.5rem;
    border-bottom: 1px solid var(--rule);
}

.xp-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Nœud timeline */
.xp-item::before {
    content: '';
    position: absolute;
    left: -2.4rem;
    top: 0.4rem;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 0 3px var(--ink), 0 0 0 4px rgba(200,168,107,0.3);
    flex-shrink: 0;
}

.xp-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 0.6rem;
    flex-wrap: wrap;
}

.xp-title {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    font-weight: 600;
    color: var(--white);
    line-height: 1.25;
}

.xp-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 0.3rem 0.8rem;
    border-radius: 100px;
    white-space: nowrap;
    flex-shrink: 0;
}

.xp-badge.stage {
    background: rgba(200,168,107,0.12);
    color: var(--gold);
    border: 1px solid rgba(200,168,107,0.3);
}

.xp-badge.formation {
    background: rgba(104,211,145,0.1);
    color: #68d391;
    border: 1px solid rgba(104,211,145,0.2);
}

.xp-badge.job {
    background: rgba(160,165,184,0.08);
    color: var(--muted-lt);
    border: 1px solid var(--rule);
}

.xp-meta {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
}

.xp-meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    color: var(--muted);
}

.xp-meta-item i {
    color: var(--gold);
    font-size: 0.72rem;
}

.xp-meta-item a {
    color: var(--muted);
    transition: color var(--ease);
}

.xp-meta-item a:hover { color: var(--gold); }

.xp-description {
    font-size: 0.95rem;
    color: var(--muted-lt);
    line-height: 1.8;
    margin-bottom: 1.4rem;
    max-width: 680px;
}

/* Grille de missions */
.xp-missions {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0.6rem;
    margin-bottom: 1.2rem;
}

.xp-mission {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.85rem;
    color: var(--muted-lt);
    line-height: 1.5;
    padding: 0.65rem 0.9rem;
    background: var(--ink-card);
    border: 1px solid var(--rule);
    border-radius: var(--r);
    transition: all var(--ease);
}

.xp-mission:hover {
    border-color: rgba(200,168,107,0.3);
    color: var(--white);
}

.xp-mission i {
    color: var(--gold);
    font-size: 0.75rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
}

/* Tags techno */
.xp-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 1rem;
}

.xp-tag {
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    color: var(--muted);
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--rule);
    padding: 0.22rem 0.65rem;
    border-radius: 3px;
    transition: all var(--ease);
}

.xp-item:hover .xp-tag {
    border-color: rgba(200,168,107,0.2);
}

@media (max-width: 768px) {
    .xp-timeline { padding-left: 1.2rem; }
    .xp-missions { grid-template-columns: 1fr; }
    .xp-header { flex-direction: column; gap: 0.6rem; }
}
