/* CSS Custom Properties & Reset */
:root {
    --bg-dark: #0d0f12;
    --bg-darker: #08090a;
    --bg-panel: rgba(26, 29, 36, 0.6);
    --text-primary: #ffffff;
    --text-secondary: #D8DBE2;
    --accent-cyan: #00F0FF;
    --accent-blue: #1E90FF;
    --font-main: 'Inter', sans-serif;
    --glow-cyan: 0 0 15px rgba(0, 240, 255, 0.4);
    --glow-blue: 0 0 15px rgba(30, 144, 255, 0.4);
    --glow-white: 0 0 15px rgba(255, 255, 255, 0.4);
    --border-glass: 1px solid rgba(255, 255, 255, 0.08);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-secondary);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
.text-primary {
    color: var(--text-primary);
    font-weight: 800;
}

.text-cyan {
    color: var(--accent-cyan);
}

.text-glow {
    text-shadow: 0 0 20px rgba(0, 240, 255, 0.5);
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Animations (applied via JS IntersectionObserver) */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Glassmorphism Panels */
.glass-panel {
    background: var(--bg-panel);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: var(--border-glass);
    border-radius: 12px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-main);
    text-align: center;
    border: none;
}

.btn-primary {
    background: var(--text-primary);
    color: var(--bg-darker);
    box-shadow: 0 4px 14px rgba(255, 255, 255, 0.2);
    transition: all 0.3s;
}

.btn-primary:hover {
    background: var(--text-secondary);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.btn-large {
    background: var(--accent-cyan);
    color: #000;
    box-shadow: var(--glow-cyan);
    padding: 16px 36px;
    font-size: 1.1rem;
}

.btn-large:hover {
    background: #fff;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.6);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--accent-cyan);
}

.btn-outline:hover {
    background: rgba(0, 240, 255, 0.1);
    box-shadow: var(--glow-cyan);
}

.btn-block {
    width: 100%;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(13, 15, 18, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: var(--border-glass);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: -0.05em;
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    background: radial-gradient(circle at center top, rgba(0, 240, 255, 0.08) 0%, transparent 50%),
        var(--bg-dark);
}

.grid-bg {
    background-image: linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
    background-size: 40px 40px;
    background-position: center center;
    width: 100%;
    text-align: center;
    padding: 80px 0;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -0.03em;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    max-width: 800px;
    margin: 0 auto 48px;
}

/* Manifesto Section */
.manifesto {
    padding: 100px 0;
    background: var(--bg-darker);
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 60px;
    letter-spacing: -0.02em;
}

.manifesto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.manifesto-card {
    padding: 40px 30px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s;
}

.manifesto-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 240, 255, 0.3);
}

.card-number {
    position: absolute;
    top: -10px;
    right: 10px;
    font-size: 8rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.15);
    z-index: 0;
}

.manifesto-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.manifesto-card p {
    position: relative;
    z-index: 1;
}

/* Equation Section */
.equation {
    padding: 120px 0;
}

.equation-visual {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 24px;
    margin-top: 40px;
}

.equation-element {
    padding: 30px 40px;
    text-align: center;
    min-width: 250px;
}

.equation-element.glow-cyan {
    border-color: rgba(0, 240, 255, 0.2);
    box-shadow: inset 0 0 20px rgba(0, 240, 255, 0.05);
}

.equation-element.glow-blue {
    border-color: rgba(30, 144, 255, 0.2);
    box-shadow: inset 0 0 20px rgba(30, 144, 255, 0.05);
}

.equation-element.glow-white {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.tag {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.equation-operator {
    font-size: 3rem;
    font-weight: 300;
    color: var(--text-secondary);
}

.equation-result {
    font-size: 2rem;
    padding: 20px 40px;
    border-bottom: 2px solid var(--accent-cyan);
}

/* Apply Section */
.apply {
    padding: 100px 0;
    background: var(--bg-darker);
    display: flex;
    justify-content: center;
}

.apply-container {
    max-width: 1000px;
    width: 100%;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 60px;
}

.apply-content h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    line-height: 1.2;
}

.apply-form {
    width: 100%;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: var(--font-main);
    font-size: 1rem;
    transition: all 0.3s;
}

#consent {
    width: unset;
    margin-right: 3px
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-cyan);
    background: rgba(0, 240, 255, 0.05);
}

.form-group select option {
    background: var(--bg-darker);
    color: var(--text-primary);
}

/* Footer */
.footer {
    padding: 60px 0;
    border-top: var(--border-glass);
    text-align: center;
}

.footer-logo {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: -15px;
}

.footer-quote {
    font-style: italic;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.footer-social a {
    display: inline-block;
    margin: 0 12px;
    color: var(--text-secondary);
}

.footer-social a:hover {
    color: var(--accent-cyan);
}

/* Animations Additional */
.delay-100 {
    transition-delay: 100ms;
}

.delay-200 {
    transition-delay: 200ms;
}

/* Consent Checkbox */
.consent-group {
    margin-bottom: 24px;
}

.consent-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
}

.consent-checkbox {
    width: auto;
    margin-top: 4px;
}

.consent-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    font-weight: normal;
}

/* Manifesto Vision Pages */
.vision-hero {
    padding-top: 140px;
    padding-bottom: 60px;
    text-align: center;
}

.vision-subtitle {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
    color: var(--text-secondary);
}

.pillars-section {
    padding: 80px 0;
    background: var(--bg-dark);
}

.pillar-card {
    margin-bottom: 60px;
    padding: 50px;
    border-left: 4px solid var(--accent-cyan);
    position: relative;
}

.pillar-card:nth-child(even) {
    border-left: none;
    border-right: 4px solid var(--accent-blue);
}

.header-logo-img {
    height: 6vw;
    max-height: 70px;
    width: auto;
    display: block;
}

.footer-logo-img {
    height: 35px;
    width: auto;
    margin: 0 auto 15px;
    display: block;
}

.footer-slogan-styled {
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    color: var(--text-secondary);
    margin-top: 5px;
    margin-bottom: 20px;
    text-transform: uppercase;
    font-weight: 700;
    opacity: 0.8;
}

.pillar-title {
    font-size: 2rem;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 16px;
    width: 100%;
}

.pillar-text {
    /* Permet au texte de se wrapper si besoin */
    overflow-wrap: break-word;
}

.pillar-tag {
    font-size: 0.9rem;
    padding: 6px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    font-weight: 600;
}

.pillar-content h4 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-top: 24px;
    margin-bottom: 12px;
}

.pillar-content ul {
    list-style: none;
    margin-top: 20px;
}

.pillar-content li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 12px;
}

.pillar-content li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--accent-cyan);
    font-weight: bold;
}

.pillar-card:nth-child(even) .pillar-content li::before {
    color: var(--accent-blue);
}

.vision-cta {
    padding: 100px 0;
    text-align: center;
    background: var(--bg-darker);
    border-top: var(--border-glass);
}

.equation-visual-left {
    justify-content: flex-start;
    margin-top: 16px;
    margin-bottom: 24px;
}

.equation-element-small {
    padding: 15px 20px;
    min-width: auto;
}

.equation-element-plain {
    border-color: rgba(255, 255, 255, 0.2);
    padding: 15px 20px;
    min-width: auto;
}

.equation-operator-small {
    font-size: 1.5rem;
}

.text-blue {
    color: var(--accent-blue);
}

.pillar-tag-future {
    background: rgba(255, 255, 255, 0.2);
}

.mt-16 {
    margin-top: 16px;
}

.mt-20 {
    margin-top: 20px;
}

.mt-30 {
    margin-top: 30px;
}

.checkbox-group {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 15px;
}

.checkbox-group .checkbox-container {
    margin-bottom: 10px;
    display: inline-block;
    width: 100%;
}

.checkbox-group .checkbox-container:last-child {
    margin-bottom: 0;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 24px;
}

.cta-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

/* Legal Pages */
.legal-hero {
    padding-top: 140px;
    padding-bottom: 60px;
    text-align: center;
    background: var(--bg-dark);
    border-bottom: var(--border-glass);
}

.legal-content {
    padding: 80px 0;
    max-width: 800px;
    margin: 0 auto;
}

.legal-content section {
    margin-bottom: 50px;
}

.legal-content h2 {
    font-size: 1.8rem;
    color: var(--accent-cyan);
    margin-bottom: 24px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.legal-content h3 {
    font-size: 1.3rem;
    color: var(--text-primary);
    margin-top: 30px;
    margin-bottom: 16px;
}

.legal-content p {
    margin-bottom: 16px;
    color: var(--text-secondary);
    line-height: 1.7;
}

.legal-content ul {
    margin-bottom: 20px;
    padding-left: 20px;
    color: var(--text-secondary);
}

.legal-content li {
    margin-bottom: 8px;
}

.legal-content a {
    color: var(--accent-blue);
    text-decoration: underline;
}

.legal-content a:hover {
    color: var(--accent-cyan);
}

.date-update {
    font-style: italic;
    color: var(--text-secondary);
    margin-top: -10px;
    margin-bottom: 40px;
}

.hero-title-large {
    font-size: 3rem;
}

/* Deleteme */
.delete-container {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

.status-box {
    max-width: 600px;
    padding: 60px;
}

.status-icon {
    font-size: 4rem;
    margin-bottom: 30px;
}

.status-title {
    font-size: 2rem;
    margin-bottom: 20px;
}

.status-message {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 40px;
}

/* Header & Footer specific */
.nav-menu {
    display: flex;
    gap: 24px;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    font-weight: 600;
    padding: 8px 0;
    transition: color 0.3s;
    position: relative;
    text-decoration: none;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 50%;
    background-color: var(--accent-cyan);
    transition: width 0.3s ease;
    transform: translateX(-50%);
    box-shadow: var(--glow-cyan);
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link:hover::after {
    width: 100%;
}

.btn-nav {
    padding: 8px 20px;
}

.footer-links-container {
    margin-top: 16px;
}

.footer-link {
    display: inline-block;
    margin: 0 12px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.footer-link:hover {
    color: var(--accent-cyan);
    transform: translateY(-2px);
    text-shadow: var(--glow-cyan);
}

/* Photo Upload Styling */
input[type="file"].file-input {
    width: 100%;
    padding: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 5px;
}

input[type="file"].file-input:hover {
    border-color: var(--accent-cyan);
    background: rgba(0, 240, 255, 0.05);
}

input[type="file"].file-input::file-selector-button {
    background: var(--bg-dark);
    color: var(--accent-cyan);
    border: 1px solid var(--accent-cyan);
    padding: 6px 15px;
    border-radius: 5px;
    cursor: pointer;
    margin-right: 15px;
    font-weight: 600;
    transition: all 0.3s;
}

input[type="file"].file-input::file-selector-button:hover {
    background: var(--accent-cyan);
    color: var(--bg-dark);
}

/* Lightbox Styling */
.clickable-img {
    cursor: zoom-in;
    transition: transform 0.3s ease;
}

.clickable-img:hover {
    transform: scale(1.05);
}

.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    overflow: hidden;
    justify-content: center;
    align-items: center;
}

.lightbox-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
    border-radius: 12px;
    box-shadow: 0 0 50px rgba(0, 240, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: zoomIn 0.3s ease-out;
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.close-lightbox {
    position: absolute;
    top: 30px;
    right: 40px;
    color: var(--text-primary);
    font-size: 50px;
    font-weight: 200;
    cursor: pointer;
    transition: color 0.3s, transform 0.3s;
    line-height: 1;
}

.close-lightbox:hover {
    color: var(--accent-cyan);
    transform: rotate(90deg);
}

.lightbox.active {
    display: flex;
}

/* --- SPLASH SCREEN ANIMATION --- */
.splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bg-dark);
    /* Solid Anthracite profond */
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

/* Pseudo-element for the cyan sweeping glow */
.splash-screen::before {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 240, 255, 0.05), transparent);
    animation: sweep 2s cubic-bezier(0.4, 0, 0.2, 1) 0.3s forwards;
}

.splash-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.splash-logo {
    width: 320px;
    max-width: 80vw;
    height: auto;
    opacity: 0.1;
    /* Start larger and partially transparent, then zoom out and become opaque */
    animation: splashLogoReveal 2s cubic-bezier(0.16, 1, 0.3, 1) 0.5s forwards;
}

.splash-signature {
    font-size: 1.3rem;
    font-weight: 300;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
    opacity: 0;
    overflow: hidden;
    white-space: nowrap;
    border-right: 2px solid var(--accent-cyan);
    margin: 0 auto;
    width: 0;
    /* Typewriter effect: longer duration, starts later */
    animation:
        typewriter 2.5s steps(48, end) 2s forwards,
        blinkCursor 0.75s step-end infinite 2s,
        hideCursor 0.1s forwards 5.5s;
}

/* Exit animation: more gradual fade + rise */
.splash-hidden {
    opacity: 0;
    transform: translateY(-120px);
    pointer-events: none;
    transition: opacity 1s ease-in, transform 1s ease-in-out;
}

/* Keyframes */
@keyframes sweep {
    0% {
        left: -150%;
    }

    100% {
        left: 200%;
    }
}

@keyframes splashLogoReveal {
    0% {
        opacity: 0.1;
        transform: scale(1.4);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes typewriter {
    from {
        width: 0;
        opacity: 1;
    }

    to {
        width: 100%;
        opacity: 1;
    }
}

@keyframes blinkCursor {

    from,
    to {
        border-color: transparent
    }

    50% {
        border-color: var(--accent-cyan);
    }
}

@keyframes hideCursor {
    to {
        border-color: transparent;
    }
}

/* --- MOBILE MENU TOGGLE --- */
.mobile-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 30px;
    height: 30px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1100;
    padding: 0;
    transition: transform 0.3s;
}

.mobile-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Toggle Open State (Hamburger to X) */
.mobile-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.mobile-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --- RESPONSIVE DESIGN --- */

/* Breackpoint Tablettes / écrans moyens */
@media (max-width: 1100px) {
    .equation-visual {
        flex-direction: column;
    }

    .equation-operator {
        transform: rotate(90deg);
        margin: -10px 0;
    }
}

@media (max-width: 992px) {
    .apply-container {
        grid-template-columns: 1fr;
        padding: 40px 24px;
    }
}

/* Breackpoint Mobiles / petits écrans */
@media (max-width: 767px) {

    /* Header & Navigation */
    .header-container {
        display: flex;
        justify-content: center;
        align-items: center;
        position: relative;
        height: 70px;
        padding: 0 15px;
    }

    .mobile-toggle {
        display: flex;
        position: absolute;
        left: 15px;
        z-index: 1100;
    }

    .logo {
        display: flex;
        justify-content: center;
        align-items: center;
        width: auto;
    }

    .header-logo-img {
        width: 25vw;
        max-width: 110px;
        height: auto;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: rgba(13, 15, 18, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 1050;
        padding: 40px;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-link {
        font-size: 1.5rem;
    }

    /* Hero & Sections */
    .hero-title {
        font-size: 2rem;
        margin-top: 37px;
    }

    .hero,
    .vision-hero,
    .legal-hero {
        padding-top: 130px;
    }

    .apply-container {
        padding: 30px 20px;
    }

    .pillar-card {
        padding: 30px;
    }

    .pillar-card:nth-child(even) {
        border-right: none;
        border-left: 4px solid var(--accent-blue);
    }

    .pillar-title {
        flex-direction: column-reverse;
        /* Remet le tag (2ème dans le HTML) au-dessus */
        align-items: flex-start;
        gap: 12px;
    }

    /* Splash Screen */
    .splash-logo {
        width: 220px;
    }

    .splash-signature {
        font-size: 0.9rem;
    }
}