@charset "UTF-8";

:root {
    --bg-color: #f4f6fa;
    --text-main: #2b2b36;
    --text-muted: #5c5c70;
    --accent-color: #b8860b; /* Goldenrod/Or chaud */
    --accent-glow: rgba(184, 134, 11, 0.4);
    --glass-bg: rgba(255, 255, 255, 0.65);
    --glass-border: rgba(184, 134, 11, 0.15);
    --nav-height: 80px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Outfit', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

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

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

#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
}

h2 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent-color);
    border-radius: 2px;
}

p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.highlight {
    color: var(--accent-color);
    font-weight: 400;
}

.quote-block {
    position: relative;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    background: rgba(255, 255, 255, 0.4);
    border-left: 4px solid var(--accent-color);
    border-radius: 0 12px 12px 0;
    font-style: italic;
    color: var(--text-main);
}

.quote-source {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    font-family: var(--font-mono);
    color: var(--accent-color);
    font-style: normal;
}

/* Glassmorphism */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
}

/* Navigation */
.glass-nav {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--nav-height);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    display: flex;
    align-items: center;
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    width: 90%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-weight: 600;
    font-size: 1.2rem;
    letter-spacing: 1px;
    color: var(--text-main);
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--accent-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5%;
    position: relative;
}

.hero-content {
    max-width: 800px;
    text-align: center;
    z-index: 1;
}

.subtitle {
    font-size: 1.2rem;
    margin-top: 1.5rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Content Layout */
.content-section {
    padding: 6rem 5%;
    position: relative;
}

.section-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.text-content {
    z-index: 2;
}

.canvas-container {
    height: 400px;
    width: 100%;
    position: relative;
    border-radius: 16px;
    overflow: hidden;
}

.canvas-container canvas {
    width: 100%;
    height: 100%;
    border-radius: 16px;
}

/* Animations & Reveals */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

.fade-in {
    animation: fadeIn 1.5s ease-out forwards;
}

.delay-1 {
    animation-delay: 0.5s;
    opacity: 0;
}

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

/* IA Lab Details */
.ia-details {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    margin: 2rem auto;
    max-width: 1000px;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.ia-details summary {
    padding: 1.5rem;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--accent-color);
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ia-details summary::-webkit-details-marker {
    display: none;
}

.ia-details summary::after {
    content: '+';
    font-size: 1.5rem;
    transition: transform 0.3s;
}

.ia-details[open] summary::after {
    transform: rotate(45deg);
}

.ia-content {
    padding: 0 1.5rem 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}

/* Reconnaissance Section */
.reconnaissance {
    text-align: center;
    max-width: 800px;
    margin: 4rem auto;
    padding: 3rem;
}

.reconnaissance p {
    font-style: italic;
    opacity: 0.8;
}

/* Footer */
footer {
    padding: 4rem 5%;
    background: rgba(255, 255, 255, 0.9);
    border-top: 1px solid var(--glass-border);
    text-align: center;
}

.footer-links {
    margin: 2rem 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

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

@media (max-width: 768px) {
    .section-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        display: none;
    }
}

/* -------------------------------------------
   RESPONSIVE TEXT & OVERFLOW FIXES (Mobile)
   ------------------------------------------- */
body {
    word-break: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    hyphens: auto;
}
.math-display, .math-box, .ia-content, pre, code {
    overflow-x: auto;
    overflow-y: hidden;
    max-width: 100%;
}
@media (max-width: 768px) {
    .glass-panel {
        padding: 1.5rem !important;
    }
    .ia-details {
        padding: 1rem 1.2rem !important;
    }
    .hero h1 {
        font-size: 2.2rem !important;
    }
    .section {
        padding: 4rem 0 !important;
    }
    .container {
        padding: 0 1rem !important;
    }
}
