/* Thème cosmique bleu */
/* Base locale remplaçant Bootstrap/CDN: reset, grille, utilitaires et icônes minimales. */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    line-height: 1.5;
}

h1,
h2,
h3,
h4,
h5,
h6,
p,
ul {
    margin-top: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    line-height: 1.2;
}

h1 {
    margin-bottom: 0.5rem;
}

h2,
h3,
h5,
h6 {
    margin-bottom: 0.5rem;
}

p,
ul {
    margin-bottom: 1rem;
}

a {
    color: var(--primary-strong);
}

button,
input,
textarea {
    font: inherit;
}

button {
    border: 0;
}

code {
    color: var(--primary-strong);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

.container {
    width: min(100% - 2rem, 1140px);
    margin-inline: auto;
}

.row {
    --grid-gutter-x: 1.5rem;
    --grid-gutter-y: 0;
    display: flex;
    flex-wrap: wrap;
    margin-top: calc(-1 * var(--grid-gutter-y));
    margin-right: calc(-0.5 * var(--grid-gutter-x));
    margin-left: calc(-0.5 * var(--grid-gutter-x));
}

.row > * {
    width: 100%;
    max-width: 100%;
    padding-right: calc(var(--grid-gutter-x) * 0.5);
    padding-left: calc(var(--grid-gutter-x) * 0.5);
    margin-top: var(--grid-gutter-y);
}

.g-3 {
    --grid-gutter-x: 1rem;
    --grid-gutter-y: 1rem;
}

.g-4 {
    --grid-gutter-x: 1.5rem;
    --grid-gutter-y: 1.5rem;
}

.col-6 {
    flex: 0 0 auto;
    width: 50%;
}

.col-12 {
    flex: 0 0 auto;
    width: 100%;
}

.navbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 0.5rem 0;
}

.navbar > .container {
    display: flex;
    flex-wrap: inherit;
    align-items: center;
}

.navbar > .container:not(.justify-content-center) {
    justify-content: space-between;
}

.navbar-nav {
    display: flex;
    flex-direction: column;
    padding-left: 0;
    margin-bottom: 0;
    list-style: none;
}

.navbar-collapse {
    flex-basis: 100%;
    flex-grow: 1;
    align-items: center;
}

.collapse:not(.show) {
    display: none;
}

.navbar-toggler {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 40px;
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border);
    border-radius: 10px;
    cursor: pointer;
}

.navbar-toggler-icon {
    position: relative;
    width: 1.4rem;
    height: 2px;
    background: currentColor;
    border-radius: 999px;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    background: currentColor;
    border-radius: inherit;
}

.navbar-toggler-icon::before {
    top: -7px;
}

.navbar-toggler-icon::after {
    top: 7px;
}

.fixed-top {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1030;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.1rem;
    text-decoration: none;
    cursor: pointer;
}

.btn-sm {
    padding: 8px 12px;
    font-size: 0.9rem;
}

.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
}

.rounded-pill {
    border-radius: 999px;
}

.form-control {
    display: block;
    width: 100%;
}

.list-unstyled {
    padding-left: 0;
    list-style: none;
}

.list-inline {
    padding-left: 0;
    list-style: none;
}

.list-inline-item {
    display: inline-block;
}

.list-inline-item:not(:last-child) {
    margin-right: 0.5rem;
}

.d-flex {
    display: flex;
}

.d-grid {
    display: grid;
}

.flex-column {
    flex-direction: column;
}

.flex-wrap {
    flex-wrap: wrap;
}

.align-items-center {
    align-items: center;
}

.align-items-stretch {
    align-items: stretch;
}

.justify-content-center {
    justify-content: center;
}

.justify-content-between {
    justify-content: space-between;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 1rem;
}

.mx-auto {
    margin-right: auto;
    margin-left: auto;
}

.mt-1 {
    margin-top: 0.25rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-3 {
    margin-top: 1rem;
}

.mt-4 {
    margin-top: 1.5rem;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-3 {
    margin-bottom: 1rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.me-2 {
    margin-right: 0.5rem;
}

.w-100 {
    width: 100%;
}

.h-100 {
    height: 100%;
}

.position-relative {
    position: relative;
}

.text-center {
    text-align: center;
}

.text-uppercase {
    text-transform: uppercase;
}

.text-white {
    color: #fff;
}

.text-primary {
    color: var(--primary-strong);
}

.small {
    font-size: 0.875em;
}

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

.bi {
    display: inline-block;
    min-width: 1em;
    color: inherit;
    font-style: normal;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    vertical-align: -0.1em;
}

.bi::before {
    content: '+';
}

.bi-arrow-left::before { content: '<'; }
.bi-arrow-up::before { content: '^'; }
.bi-check2-circle::before,
.bi-check-circle-fill::before { content: 'OK'; font-size: 0.62em; letter-spacing: 0.04em; }
.bi-code-slash::before { content: 'DEV'; font-size: 0.62em; letter-spacing: 0.04em; }
.bi-cup-hot::before { content: 'CAFE'; font-size: 0.55em; letter-spacing: 0.03em; }
.bi-database::before { content: 'DB'; font-size: 0.72em; }
.bi-diagram-3::before { content: 'NET'; font-size: 0.62em; letter-spacing: 0.04em; }
.bi-envelope::before,
.bi-envelope-at::before { content: '@'; }
.bi-file-earmark-arrow-down::before,
.bi-file-earmark-person::before { content: 'PDF'; font-size: 0.7em; }
.bi-folder2-open::before { content: 'DIR'; font-size: 0.68em; letter-spacing: 0.04em; }
.bi-github::before { content: 'GH'; font-size: 0.7em; }
.bi-mortarboard::before { content: 'BTS'; font-size: 0.68em; letter-spacing: 0.04em; }
.bi-person-workspace::before { content: 'PRO'; font-size: 0.68em; letter-spacing: 0.04em; }
.bi-rocket-takeoff::before { content: 'GO'; font-size: 0.72em; letter-spacing: 0.04em; }
.bi-server::before { content: 'SRV'; font-size: 0.62em; letter-spacing: 0.04em; }
.bi-shield-check::before,
.bi-shield-lock::before { content: 'SEC'; font-size: 0.62em; letter-spacing: 0.04em; }

@media (min-width: 768px) {
    .col-md-3 {
        flex: 0 0 auto;
        width: 25%;
    }

    .col-md-6 {
        flex: 0 0 auto;
        width: 50%;
    }

    .flex-md-row {
        flex-direction: row;
    }
}

@media (min-width: 992px) {
    .col-lg-3 {
        flex: 0 0 auto;
        width: 25%;
    }

    .col-lg-4 {
        flex: 0 0 auto;
        width: 33.333333%;
    }

    .col-lg-5 {
        flex: 0 0 auto;
        width: 41.666667%;
    }

    .col-lg-7 {
        flex: 0 0 auto;
        width: 58.333333%;
    }

    .col-lg-8 {
        flex: 0 0 auto;
        width: 66.666667%;
    }

    .navbar-expand-lg {
        flex-wrap: nowrap;
        justify-content: flex-start;
    }

    .navbar-expand-lg .navbar-nav {
        flex-direction: row;
    }

    .navbar-expand-lg .navbar-collapse {
        display: flex !important;
        flex-basis: auto;
    }

    .navbar-expand-lg .navbar-toggler {
        display: none;
    }
}

:root {
    /* Variables globales (couleurs, rayons, ombres). */
    --bg: #050c1d;
    --bg-strong: #07152d;
    --bg-soft: rgba(16, 34, 64, 0.8);
    --primary: #3fa2ff;
    --primary-strong: #68c3ff;
    --primary-violet: #8f75ff;
    --text: #e9f0ff;
    --muted: #94a8c9;
    --input-bg: rgba(255, 255, 255, 0.1);
    --input-bg-focus: rgba(255, 255, 255, 0.16);
    --input-text: #f4f8ff;
    --placeholder: rgba(233, 240, 255, 0.7);
    --input-border: rgba(120, 170, 255, 0.5);
    --border: rgba(255, 255, 255, 0.1);
    --card: rgba(13, 26, 52, 0.75);
    --shadow: 0 15px 45px rgba(23, 63, 122, 0.35);
    --radius: 16px;
    --glow-blue: rgba(88, 182, 255, 0.35);
    --glow-violet: rgba(143, 117, 255, 0.24);
}

/* Palette alternative conservee pour compatibilite future (non activee par defaut). */
.theme-light {
    --bg: #f7f9fc;
    --bg-strong: #ffffff;
    --bg-soft: rgba(255, 255, 255, 0.9);
    --primary: #2155d9;
    --primary-strong: #1b44b6;
    --text: #1c2140;
    --muted: #4b5876;
    --input-bg: rgba(255, 255, 255, 0.95);
    --input-bg-focus: #ffffff;
    --input-text: #1c2140;
    --placeholder: #7a8299;
    --input-border: rgba(32, 55, 110, 0.2);
    --border: rgba(18, 51, 102, 0.12);
    --card: rgba(255, 255, 255, 0.95);
    --shadow: 0 12px 30px rgba(20, 35, 70, 0.12);
}

/* Fond global spatial: gradients + texture d'etoiles. */
body {
    --parallax-offset: 0px;
    font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
    background:
        radial-gradient(circle at 20% 20%, rgba(63, 162, 255, 0.12), transparent 30%),
        radial-gradient(circle at 72% 18%, rgba(143, 117, 255, 0.08), transparent 34%),
        radial-gradient(circle at 80% 10%, rgba(104, 195, 255, 0.1), transparent 35%),
        linear-gradient(180deg, var(--bg-strong), var(--bg));
    color: var(--text);
    transition: background 0.4s ease, color 0.4s ease;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Couche d'etoiles fines en arriere-plan. */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
        radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px);
    background-size: 140px 140px, 220px 220px;
    background-position: 0 0, 40px 60px;
    opacity: 0.35;
    animation: starfield-drift 46s linear infinite;
    transform: translate3d(0, calc(var(--parallax-offset) * 0.08), 0);
    will-change: transform, opacity;
    pointer-events: none;
    z-index: -1;
}

/* Couche de nebulosite diffuse. */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 80% 10%, rgba(63, 162, 255, 0.12), transparent 35%),
                radial-gradient(circle at 10% 80%, rgba(86, 199, 255, 0.1), transparent 30%),
                radial-gradient(circle at 62% 78%, rgba(143, 117, 255, 0.08), transparent 34%);
    background-size: 120% 120%;
    animation: nebula-drift 18s ease-in-out infinite alternate;
    transform: translate3d(0, calc(var(--parallax-offset) * 0.16), 0);
    will-change: transform, opacity;
    pointer-events: none;
    z-index: -2;
}

/* Troisieme couche d'etoiles pour profondeur parallax. */
.cosmic-depth-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -3;
    opacity: 0.24;
    background-image:
        radial-gradient(rgba(189, 222, 255, 0.22) 0.7px, transparent 1px),
        radial-gradient(rgba(147, 170, 255, 0.18) 0.7px, transparent 1px);
    background-size: 260px 260px, 340px 340px;
    background-position: 0 0, 85px 45px;
    mix-blend-mode: screen;
    transform: translate3d(0, calc(var(--parallax-offset) * 0.24), 0);
    animation: deep-star-drift 64s linear infinite;
    will-change: transform, opacity;
}

@keyframes starfield-drift {
    from {
        background-position: 0 0, 40px 60px;
    }
    to {
        background-position: 64px 48px, 110px 136px;
    }
}

@keyframes nebula-drift {
    from {
        transform: translate3d(0, 0, 0) scale(1);
        opacity: 1;
    }
    to {
        transform: translate3d(-1.5%, -1%, 0) scale(1.03);
        opacity: 0.85;
    }
}

@keyframes deep-star-drift {
    from {
        background-position: 0 0, 85px 45px;
    }
    to {
        background-position: 130px 96px, 210px 182px;
    }
}

/* Navigation principale fixe. */
.navbar {
    background: rgba(6, 14, 30, 0.82);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    letter-spacing: 0.01em;
}

.navbar .navbar-collapse {
    justify-content: center;
}

.navbar .navbar-nav {
    margin-left: auto;
    margin-right: auto;
}

.navbar .navbar-toggler {
    margin-left: auto;
}

.navbar-brand {
    font-weight: 700;
}

/* Variante logo en bloc (non utilisee actuellement). */
.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(140deg, var(--primary), var(--primary-strong));
    color: #041029;
    font-weight: 700;
    box-shadow: 0 10px 26px rgba(63, 162, 255, 0.4);
}

/* Logo image de la marque. */
.brand-logo {
    width: 34px;
    height: 34px;
    display: inline-block;
    border-radius: 10px;
    object-fit: contain;
    object-position: center;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    box-shadow: 0 10px 26px rgba(63, 162, 255, 0.4);
}

/* Liens du menu et etat actif. */
.nav-link {
    display: block;
    color: var(--muted) !important;
    position: relative;
    padding: 0.75rem 1rem !important;
    text-decoration: none;
}

.nav-link:hover,
.nav-link:focus {
    color: var(--text) !important;
}

.nav-link.active {
    color: #fff !important;
}

.nav-link.active::after,
.nav-link:hover::after {
    content: '';
    position: absolute;
    left: 1rem;
    right: 1rem;
    bottom: 8px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 1;
}

/* Hero d'introduction (zone visible au chargement). */
.hero {
    position: relative;
    padding: 160px 0 120px;
    text-align: center;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 22% 14%, rgba(99, 195, 255, 0.18), transparent 34%),
        radial-gradient(circle at 74% 12%, rgba(143, 117, 255, 0.16), transparent 36%),
        linear-gradient(160deg, rgba(16, 30, 64, 0.62), rgba(5, 12, 29, 0.84));
    background-size: 110% 110%;
    animation: hero-cosmic-pan 14s ease-in-out infinite alternate;
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: url('../../images/hero-bg-1200.jpg') center/cover no-repeat;
    background-image: image-set(
        url('../../images/hero-bg-1200.webp') type('image/webp'),
        url('../../images/hero-bg-1200.jpg') type('image/jpeg')
    );
    opacity: 0.15;
    mix-blend-mode: screen;
    transform: translate3d(0, calc(var(--parallax-offset) * 0.12), 0) scale(1.02);
    will-change: transform;
}

.hero-with-image::after {
    content: none;
}

.hero-bg-picture {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.15;
    mix-blend-mode: screen;
    transform: translate3d(0, calc(var(--parallax-offset) * 0.12), 0) scale(1.02);
    will-change: transform;
    pointer-events: none;
}

.hero-bg-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.hero-layout {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
    align-items: center;
    gap: clamp(24px, 4vw, 56px);
    text-align: left;
}

.hero-layout::before {
    content: '';
    position: absolute;
    inset: 8% 0 auto auto;
    width: min(42vw, 520px);
    height: min(42vw, 520px);
    background:
        linear-gradient(rgba(104, 195, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(104, 195, 255, 0.08) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: radial-gradient(circle, #000 0 42%, transparent 68%);
    opacity: 0.5;
    pointer-events: none;
}

.hero-copy {
    position: relative;
    z-index: 1;
    max-width: 760px;
}

.hero h1 {
    font-size: clamp(2.4rem, 3vw + 1rem, 3.6rem);
    font-weight: 700;
    text-shadow:
        0 10px 30px rgba(0, 0, 0, 0.35),
        0 0 20px rgba(88, 182, 255, 0.28),
        0 0 32px rgba(143, 117, 255, 0.16);
    animation: hero-title-glow 4.8s ease-in-out infinite;
}

@keyframes hero-cosmic-pan {
    from {
        background-position: 0% 0%;
    }
    to {
        background-position: 10% 14%;
    }
}

@keyframes hero-title-glow {
    0%, 100% {
        text-shadow:
            0 10px 30px rgba(0, 0, 0, 0.35),
            0 0 18px rgba(88, 182, 255, 0.24),
            0 0 28px rgba(143, 117, 255, 0.12);
    }
    50% {
        text-shadow:
            0 12px 34px rgba(0, 0, 0, 0.42),
            0 0 24px rgba(88, 182, 255, 0.34),
            0 0 38px rgba(143, 117, 255, 0.22);
    }
}

.hero-lead {
    max-width: 720px;
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 1.05rem;
}

.hero-eyebrow {
    letter-spacing: 0.25em;
    font-size: 0.8rem;
    color: var(--primary-strong);
    margin-bottom: 10px;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    color: var(--muted);
    gap: 12px;
}

.hero-actions {
    justify-content: flex-start;
}

.hero-highlights {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px;
}

.highlight-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    min-width: 0;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background:
        linear-gradient(135deg, rgba(63, 162, 255, 0.14), rgba(143, 117, 255, 0.08)),
        rgba(255, 255, 255, 0.08);
    color: var(--text);
    font-size: 0.88rem;
    text-align: center;
    white-space: normal;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.hero-panel {
    position: relative;
    z-index: 1;
    padding: 22px;
    border: 1px solid rgba(104, 195, 255, 0.22);
    border-radius: calc(var(--radius) + 6px);
    background:
        linear-gradient(145deg, rgba(13, 26, 52, 0.88), rgba(20, 42, 78, 0.68)),
        radial-gradient(circle at 20% 0%, rgba(104, 195, 255, 0.18), transparent 32%);
    box-shadow:
        0 24px 60px rgba(0, 0, 0, 0.28),
        0 0 34px rgba(63, 162, 255, 0.16);
    backdrop-filter: blur(16px);
}

.hero-panel::before,
.hero-panel::after {
    content: '';
    position: absolute;
    pointer-events: none;
}

.hero-panel::before {
    inset: 18px;
    border-radius: 18px;
    background:
        linear-gradient(90deg, transparent 0 18%, rgba(104, 195, 255, 0.2) 18% 19%, transparent 19% 100%),
        linear-gradient(0deg, transparent 0 48%, rgba(104, 195, 255, 0.18) 48% 49%, transparent 49% 100%);
    opacity: 0.24;
}

.hero-panel::after {
    right: 18px;
    top: 18px;
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: var(--primary-strong);
    box-shadow:
        -70px 58px 0 rgba(104, 195, 255, 0.62),
        -148px 112px 0 rgba(143, 117, 255, 0.54),
        -42px 174px 0 rgba(104, 195, 255, 0.45);
    opacity: 0.75;
}

.hero-panel-kicker {
    position: relative;
    z-index: 1;
    margin-bottom: 16px;
    color: var(--primary-strong);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.hero-panel-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.hero-panel-item {
    position: relative;
    min-height: 94px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.055);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.hero-panel-item::before {
    content: '';
    position: absolute;
    left: 14px;
    top: 14px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--primary-strong);
    box-shadow: 0 0 14px rgba(104, 195, 255, 0.55);
}

.hero-panel-value {
    color: #fff;
    font-size: 1.18rem;
    font-weight: 800;
}

.hero-panel-label {
    color: var(--muted);
    font-size: 0.86rem;
}

/* Blocs de section reutilisables. */
.section-block {
    padding: 80px 0;
    position: relative;
}

.section-header {
    margin-bottom: 32px;
}

.section-kicker {
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--primary-strong);
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 8px;
}

.section-title {
    margin-bottom: 12px;
    font-weight: 700;
    text-transform: none;
    text-shadow: 0 0 14px rgba(88, 182, 255, 0.12);
}

.section-desc {
    max-width: 720px;
    color: var(--muted);
}

/* Reveal au scroll: fluide et leger, sans decalage de layout. */
.reveal-init {
    opacity: 0;
    transform: translate3d(0, 20px, 0);
    filter: blur(8px);
    transition:
        opacity 300ms ease-out var(--reveal-delay, 0ms),
        transform 300ms ease-out var(--reveal-delay, 0ms),
        filter 300ms ease-out var(--reveal-delay, 0ms);
    will-change: opacity, transform, filter;
}

.reveal-init.is-visible {
    opacity: 1;
    transform: translate3d(0, 0, 0);
    filter: blur(0);
}

/* Zone parcours (timeline). */
.section-journey {
    background: linear-gradient(180deg, rgba(6, 13, 27, 0), rgba(18, 32, 57, 0.26));
}

/* Carte "glass" generique reutilisee partout. */
.glass-card {
    background:
        linear-gradient(160deg, rgba(255, 255, 255, 0.035), transparent 45%),
        var(--card);
    border: 1px solid rgba(104, 195, 255, 0.12);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow:
        var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.045);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(130deg, rgba(63, 162, 255, 0.08), transparent 60%);
    opacity: 0.8;
    pointer-events: none;
    z-index: 0;
}

.glass-card::after {
    content: '';
    position: absolute;
    right: -48px;
    bottom: -48px;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(104, 195, 255, 0.12), transparent 64%);
    pointer-events: none;
    z-index: 0;
}

.glass-card > * {
    position: relative;
    z-index: 1;
}

.card-heading,
.skill-heading {
    color: #fff;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.card-heading {
    font-size: 0.83em;
}

.skill-heading {
    font-size: 0.67em;
}

.highlight-card {
    background: linear-gradient(160deg, rgba(63, 162, 255, 0.18), var(--card));
}

.stat-number {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-strong);
}

.info-list li {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.info-list li:last-child {
    margin-bottom: 0;
}

/* Timeline du parcours. */
.timeline {
    display: grid;
    gap: 16px;
}

.timeline-item {
    padding-left: 60px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 24px;
    top: 30px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary-strong);
    box-shadow: 0 0 0 6px rgba(104, 195, 255, 0.12);
}

.timeline-item:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 29px;
    top: 44px;
    bottom: -18px;
    width: 2px;
    background: linear-gradient(180deg, rgba(104, 195, 255, 0.4), rgba(104, 195, 255, 0.08));
}

.timeline-year {
    font-size: 0.82rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--primary-strong);
    margin-bottom: 8px;
}

/* Cartes projets + tags techniques. */
.project-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 28px;
    background:
        radial-gradient(circle at 12% 0%, rgba(104, 195, 255, 0.13), transparent 34%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 55%),
        var(--card);
    transform: translate3d(0, 0, 0) scale(1);
    transform-origin: center;
    transition:
        transform 200ms ease,
        box-shadow 200ms ease,
        border-color 200ms ease,
        background-color 200ms ease;
}

.project-card > * {
    position: relative;
    z-index: 1;
}

.project-card .d-flex {
    gap: 10px;
}

.project-card p {
    color: var(--muted);
}

.project-card::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    border: 1px solid transparent;
    background:
        linear-gradient(135deg, rgba(88, 182, 255, 0.4), rgba(143, 117, 255, 0.32)) border-box;
    -webkit-mask:
        linear-gradient(#fff 0 0) padding-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease;
}

.project-card .tags,
.project-card .d-grid {
    transition: transform 200ms ease, opacity 200ms ease;
}

.project-card .d-grid {
    transform: translate3d(0, 6px, 0);
    opacity: 0.93;
}

.project-card:hover,
.project-card:focus-within {
    transform: translate3d(0, -6px, 0) scale(1.02);
    box-shadow:
        0 26px 52px rgba(26, 76, 152, 0.45),
        0 0 28px var(--glow-blue),
        0 0 36px var(--glow-violet);
    border-color: rgba(104, 195, 255, 0.48);
    background-color: rgba(15, 31, 60, 0.82);
}

.project-card:hover::after,
.project-card:focus-within::after {
    opacity: 1;
}

.project-card:hover .tags,
.project-card:focus-within .tags {
    transform: translate3d(0, -2px, 0);
}

.project-card:hover .d-grid,
.project-card:focus-within .d-grid {
    transform: translate3d(0, 0, 0);
    opacity: 1;
}

.badge.text-bg-dark {
    background: rgba(104, 195, 255, 0.13) !important;
    color: var(--text);
    border: 1px solid rgba(104, 195, 255, 0.26);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tags span {
    display: inline-block;
    padding: 6px 12px;
    background: rgba(104, 195, 255, 0.08);
    border: 1px solid rgba(104, 195, 255, 0.18);
    border-radius: 999px;
    color: #c6d7f5;
    font-size: 0.85rem;
    margin-right: 8px;
    margin-bottom: 8px;
}

.project-status {
    color: var(--primary-strong);
    font-weight: 600;
    font-size: 0.9rem;
}

/* Liens rapides de la section contact. */
.contact-links {
    display: grid;
    gap: 10px;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.contact-link i {
    font-size: 1.05rem;
    color: var(--primary-strong);
}

.contact-link:hover {
    transform: translateY(-2px);
    border-color: rgba(104, 195, 255, 0.6);
    color: var(--text);
}

/* Cartes competences. */
.skill-card {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background:
        radial-gradient(circle at 50% 0%, rgba(63, 162, 255, 0.15), transparent 36%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 60%),
        var(--card);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.skill-card::after {
    width: 120px;
    height: 120px;
}

.skill-card i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(104, 195, 255, 0.24);
    border-radius: 18px;
    background:
        linear-gradient(145deg, rgba(63, 162, 255, 0.18), rgba(143, 117, 255, 0.12));
    font-size: 1.55rem;
    color: var(--primary-strong);
    margin-bottom: 6px;
    box-shadow: 0 12px 28px rgba(63, 162, 255, 0.16);
}

.skill-card p {
    max-width: 190px;
    margin-right: auto;
    margin-left: auto;
}

.skill-card:hover {
    transform: translateY(-6px);
    border-color: rgba(104, 195, 255, 0.4);
    box-shadow:
        0 18px 40px rgba(63, 162, 255, 0.3),
        0 0 24px rgba(143, 117, 255, 0.16);
}

/* Boutons generiques et variantes. */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-height: 46px;
    border-radius: 14px;
    padding: 12px 20px;
    font-weight: 600;
    line-height: 1.2;
    transform: translate3d(0, 0, 0) scale(1);
    transition:
        transform 150ms ease,
        box-shadow 150ms ease,
        border-color 150ms ease,
        background-color 150ms ease,
        color 150ms ease;
}

.btn:not(:disabled):hover {
    transform: translate3d(0, 0, 0) scale(1.03);
    box-shadow:
        0 14px 34px rgba(63, 162, 255, 0.28),
        0 0 18px rgba(88, 182, 255, 0.25);
}

.btn:not(:disabled):active {
    transform: translate3d(0, 0, 0) scale(0.97);
    box-shadow: 0 6px 14px rgba(63, 162, 255, 0.2);
}

.btn-primary {
    background: linear-gradient(120deg, var(--primary), var(--primary-strong));
    border: 1px solid var(--primary-strong);
    color: #041029;
    box-shadow: 0 10px 30px rgba(63, 162, 255, 0.35);
}

.btn-primary:hover,
.btn-primary:focus-visible,
.btn-primary:visited {
    background: linear-gradient(120deg, var(--primary-strong), var(--primary));
    color: #041029;
    box-shadow:
        0 14px 34px rgba(63, 162, 255, 0.35),
        0 0 22px rgba(88, 182, 255, 0.3),
        0 0 28px rgba(143, 117, 255, 0.2);
}

.btn-outline-light {
    --bs-btn-color: var(--text);
    --bs-btn-border-color: var(--border);
    --bs-btn-bg: rgba(255, 255, 255, 0.05);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: rgba(63, 162, 255, 0.18);
    --bs-btn-hover-border-color: var(--primary-strong);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: rgba(63, 162, 255, 0.24);
    --bs-btn-active-border-color: var(--primary-strong);
    --bs-btn-focus-shadow-rgb: 63, 162, 255;
    color: var(--bs-btn-color);
    border: 1px solid var(--bs-btn-border-color);
    background: var(--bs-btn-bg);
}

.btn-outline-light:hover,
.btn-outline-light:focus-visible,
.btn-outline-light:active {
    border-color: var(--bs-btn-hover-border-color);
    color: var(--bs-btn-hover-color);
    background: var(--bs-btn-hover-bg);
    box-shadow: 0 0 18px rgba(88, 182, 255, 0.22), 0 0 24px rgba(143, 117, 255, 0.14);
}

/* Champs de formulaire. */
.form-control {
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    color: var(--input-text);
    border-radius: 12px;
    padding: 12px;
}

.form-control::placeholder {
    color: var(--placeholder);
    opacity: 1;
}

.form-control:focus {
    border-color: var(--primary-strong);
    box-shadow: 0 0 0 0.15rem rgba(63, 162, 255, 0.25);
    background: var(--input-bg-focus);
    color: var(--input-text);
}

.text-muted {
    color: var(--muted) !important;
}

/* Footer. */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 24px 0 32px;
    background: rgba(3, 9, 20, 0.6);
}

.site-footer p {
    color: var(--muted);
}

.footer-links a {
    color: var(--muted);
    text-decoration: none;
}

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

/* Bandeau d'information cookies RGPD/CNIL. */
.cookie-notice {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    display: grid;
    gap: 12px;
    align-items: center;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(6, 14, 30, 0.96);
    box-shadow: 0 14px 36px rgba(4, 10, 26, 0.52);
    z-index: 80;
    opacity: 0;
    transform: translateY(14px);
    pointer-events: none;
    transition: opacity 0.24s ease, transform 0.24s ease;
}

.cookie-notice.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.cookie-notice-text {
    margin: 0;
    color: var(--text);
    font-size: 0.92rem;
    line-height: 1.4;
}

.cookie-notice-text a {
    color: var(--primary-strong);
}

.cookie-notice-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Couche de rendu pour l'effet etoiles filantes au curseur. */
.mouse-star-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 35;
    overflow: hidden;
}

.mouse-star {
    position: absolute;
    top: 0;
    left: 0;
    width: var(--star-size, 2px);
    height: var(--star-size, 2px);
    border-radius: 50%;
    background: rgba(225, 244, 255, 0.95);
    box-shadow: 0 0 10px rgba(145, 217, 255, 0.62), 0 0 18px rgba(102, 195, 255, 0.4);
    transform: translate(-50%, -50%) rotate(var(--shoot-rotate, 0deg));
    opacity: 0;
    will-change: transform, opacity;
    animation: shooting-star var(--star-duration, 460ms) cubic-bezier(0.2, 0.65, 0.25, 1) forwards;
}

.mouse-star::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: var(--trail-length, 24px);
    height: 1.6px;
    border-radius: 999px;
    transform: translate(-100%, -50%);
    background: linear-gradient(90deg, rgba(95, 185, 255, 0), rgba(143, 220, 255, 0.52), rgba(225, 247, 255, 0.95));
    filter: blur(0.2px);
}

.mouse-star.soft {
    opacity: 0.45;
}

/* Animation d'une particule "etoile filante". */
@keyframes shooting-star {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) rotate(var(--shoot-rotate, 0deg)) scale(0.74);
    }
    18% {
        opacity: 0.9;
    }
    100% {
        opacity: 0;
        transform: translate(calc(-50% + var(--shoot-x, 0px)), calc(-50% + var(--shoot-y, 0px))) rotate(var(--shoot-rotate, 0deg)) scale(0.62);
    }
}

/* Ajustement du bandeau cookies sur ecrans moyens/grands. */
@media (min-width: 768px) {
    .cookie-notice {
        left: 24px;
        right: 24px;
        bottom: 20px;
        grid-template-columns: 1fr auto;
    }
}

/* Coupe les effets souris sur mobile et pour accessibilite motion-reduce. */
@media (hover: none), (pointer: coarse), (prefers-reduced-motion: reduce) {
    .mouse-star-layer {
        display: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cosmic-depth-layer {
        display: none !important;
    }

    body::before,
    body::after {
        animation: none !important;
        transform: none !important;
    }

    .hero::before,
    .hero h1 {
        animation: none !important;
    }

    .hero::after,
    .hero-bg-picture {
        transform: none !important;
    }

    .reveal-init {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        transition: none !important;
    }

    .project-card,
    .project-card::after,
    .project-card .tags,
    .project-card .d-grid,
    .skill-card,
    .btn {
        transition: none !important;
    }

    .project-card:hover,
    .project-card:focus-within,
    .btn:hover,
    .btn:active {
        transform: none !important;
    }
}

/* Bouton flottant retour en haut. */
.btn-to-top {
    position: fixed;
    bottom: 22px;
    right: 22px;
    display: none;
    background: linear-gradient(150deg, var(--primary), var(--primary-strong));
    color: #041029;
    border: none;
    padding: 12px 14px;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 10px 26px rgba(63, 162, 255, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    z-index: 50;
}

.btn-to-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px rgba(63, 162, 255, 0.45);
}

.btn-to-top.show {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Theme clair (conserve pour evolution future). */
.theme-light .navbar {
    background: rgba(255, 255, 255, 0.88);
    border-bottom-color: rgba(16, 30, 64, 0.1);
}

.theme-light .navbar-brand {
    color: #0f172a !important;
}

.theme-light .navbar-toggler {
    border-color: rgba(15, 23, 42, 0.2);
}

.theme-light .navbar-toggler-icon {
    filter: invert(1);
}

.theme-light .nav-link {
    color: #2b3856 !important;
}

.theme-light .nav-link:hover,
.theme-light .nav-link:focus,
.theme-light .nav-link.active {
    color: #0f172a !important;
}

.theme-light .nav-link.active::after,
.theme-light .nav-link:hover::after {
    background: linear-gradient(90deg, transparent, #2155d9, transparent);
    opacity: 0.7;
}

.theme-light .hero.text-white {
    color: var(--text) !important;
}

.theme-light .hero::before {
    background: linear-gradient(160deg, rgba(248, 250, 255, 0.9), rgba(228, 236, 248, 0.95));
}

.theme-light .hero::after {
    opacity: 0.08;
    mix-blend-mode: normal;
}

.theme-light .hero-bg-picture {
    opacity: 0.08;
    mix-blend-mode: normal;
}

.theme-light .hero h1 {
    color: #0f172a;
    text-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.theme-light .hero-lead,
.theme-light .hero-meta {
    color: #4b5876;
}

.theme-light .highlight-pill {
    background:
        linear-gradient(135deg, rgba(33, 85, 217, 0.11), rgba(33, 85, 217, 0.05)),
        rgba(33, 85, 217, 0.1);
    border-color: rgba(33, 85, 217, 0.22);
    color: #1c2140;
}

.theme-light .hero-panel {
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(235, 242, 255, 0.86)),
        radial-gradient(circle at 20% 0%, rgba(33, 85, 217, 0.12), transparent 32%);
    border-color: rgba(33, 85, 217, 0.18);
}

.theme-light .hero-panel-value {
    color: #0f172a;
}

.theme-light .hero-panel-label {
    color: #4b5876;
}

.theme-light .hero-panel-item {
    background: rgba(33, 85, 217, 0.06);
    border-color: rgba(33, 85, 217, 0.12);
}

.theme-light .hero-eyebrow {
    color: #2155d9;
}

.theme-light body::before {
    opacity: 0.18;
}

.theme-light body::after {
    opacity: 0.35;
}

.theme-light .card-heading,
.theme-light .skill-heading {
    color: #0f172a;
}

.theme-light .badge.text-bg-dark {
    background: rgba(33, 85, 217, 0.12) !important;
    color: #1c2140;
    border-color: rgba(33, 85, 217, 0.25);
}

.theme-light .tags span {
    background: rgba(33, 85, 217, 0.08);
    border-color: rgba(33, 85, 217, 0.2);
    color: #2a3858;
}

.theme-light .timeline-item::before {
    box-shadow: 0 0 0 6px rgba(33, 85, 217, 0.14);
}

.theme-light .timeline-item:not(:last-child)::after {
    background: linear-gradient(180deg, rgba(33, 85, 217, 0.35), rgba(33, 85, 217, 0.1));
}

.theme-light .btn-outline-light {
    --bs-btn-color: #1c2140;
    --bs-btn-border-color: rgba(33, 85, 217, 0.25);
    --bs-btn-bg: rgba(33, 85, 217, 0.08);
    --bs-btn-hover-color: #0f172a;
    --bs-btn-hover-bg: rgba(33, 85, 217, 0.16);
    --bs-btn-hover-border-color: rgba(33, 85, 217, 0.4);
    --bs-btn-active-color: #0f172a;
    --bs-btn-active-bg: rgba(33, 85, 217, 0.22);
    --bs-btn-active-border-color: rgba(33, 85, 217, 0.45);
    color: var(--bs-btn-color);
    background: var(--bs-btn-bg);
    border-color: var(--bs-btn-border-color);
}

.theme-light .btn-outline-light:hover,
.theme-light .btn-outline-light:focus-visible,
.theme-light .btn-outline-light:active {
    color: var(--bs-btn-hover-color);
    background: var(--bs-btn-hover-bg);
    border-color: var(--bs-btn-hover-border-color);
}

.theme-light .contact-link {
    color: #1c2140;
    background: rgba(33, 85, 217, 0.08);
    border-color: rgba(33, 85, 217, 0.22);
}

.theme-light .contact-link:hover {
    color: #0f172a;
    border-color: rgba(33, 85, 217, 0.45);
}

.theme-light .site-footer {
    background: rgba(255, 255, 255, 0.76);
}

/* Responsive menu. */
@media (max-width: 991px) {
    .nav-link::after {
        display: none;
    }
}

/* Responsive mobile. */
@media (max-width: 768px) {
    .hero-layout {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-copy,
    .hero-lead {
        max-width: 100%;
    }

    .hero-lead {
        margin-right: auto;
        margin-left: auto;
    }

    .hero-actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: center;
        width: 100%;
    }

    .hero-highlights,
    .hero-meta {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: center;
        width: 100%;
        justify-content: center;
        max-width: 100%;
    }

    .hero .btn {
        width: min(100%, 320px);
        max-width: 320px;
        white-space: normal;
    }

    .hero-meta .list-inline-item {
        margin-right: 0;
    }

    .highlight-pill {
        width: min(100%, 320px);
    }

    .hero-panel {
        padding: 18px;
    }

    .hero-panel-grid {
        grid-template-columns: 1fr;
    }

    .section-block {
        padding: 64px 0;
    }

    .hero {
        padding: 140px 0 80px;
    }

    .hero::after {
        background: url('../../images/hero-bg-720.jpg') center/cover no-repeat;
        background-image: image-set(
            url('../../images/hero-bg-720.webp') type('image/webp'),
            url('../../images/hero-bg-720.jpg') type('image/jpeg')
        );
    }

    .timeline-item {
        padding-left: 52px;
    }

    .timeline-item::before {
        left: 20px;
    }

    .timeline-item:not(:last-child)::after {
        left: 25px;
    }
}
