/* --- PALETTE DE COULEURS : SAAS ÉDITORIAL (CRIMSON HYBRIDE) --- */
:root {
    --bg-color: #fdfcfb; /* Blanc craie très lumineux */
    --text-main: #1c1917; /* Pierre sombre */
    --text-muted: #625c56;
    --border-color: #e2ded5; /* Ligne SaaS ultra fine */
    --card-bg: #ffffff;
    --card-hover: #faf9f6;
    
    /* Les deux variations de tes couleurs préférées */
    --bordeaux: #6b1d2f; /* Couleur maîtresse éditoriale */
    --violet: #6d28d9; /* Accent tech interactif */
    --violet-glow: rgba(109, 40, 217, 0.03);
    
    --color-linkedin: #0A66C2;
    --color-discord: #5865F2;
}

[data-theme="dark"] {
    --bg-color: #0b0a0d; /* Noir mat pur */
    --text-main: #f5f5f4;
    --text-muted: #a8a29e;
    --border-color: #1f1d24;
    --card-bg: #121115;
    --card-hover: #19181f;
    
    --bordeaux: #ef4444; /* Rouge vif pour la lisibilité sur fond noir */
    --violet: #a78bfa; /* Violet pastel électrique */
    --violet-glow: rgba(167, 139, 250, 0.02);
}

/* --- BASES & HABILLAGE DE FOND --- */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: system-ui, -apple-system, sans-serif; }
body { 
    background-color: var(--bg-color); 
    color: var(--text-main); 
    line-height: 1.6; 
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Alignement global SaaS */
.container {
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 25px;
}

/* --- INTERRUPTEUR DE THÈME --- */
#theme-toggle {
    position: fixed; top: 20px; right: 20px; background: var(--card-bg);
    border: 1px solid var(--border-color); color: var(--text-main); padding: 8px 16px;
    border-radius: 30px; cursor: pointer; font-weight: 600; font-size: 0.8rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05); z-index: 1000; transition: 0.2s;
}
#theme-toggle:hover { border-color: var(--violet); color: var(--violet); }

/* --- HERO HEADER --- */
header { padding: 120px 0 80px; background: radial-gradient(circle at 80% 20%, var(--violet-glow), transparent 40%); }
header h1 { font-size: 3.6rem; font-weight: 800; letter-spacing: -2px; }
header h1 span { color: var(--bordeaux); font-weight: 300; font-style: italic; }
.subtitle { color: var(--text-muted); font-size: 1.2rem; max-width: 700px; margin: 20px 0 40px 0; font-weight: 400; line-height: 1.7; }

/* BUTTONS SAAS PRO */
.actions-container { display: flex; gap: 15px; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 12px 26px; border: 1px solid var(--border-color); border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 0.95rem; color: var(--text-main); background: var(--card-bg); transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); box-shadow: 0 2px 6px rgba(0,0,0,0.02); }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,0.06); border-color: var(--text-main); }
.btn svg { width: 18px; height: 18px; fill: currentColor; }

.btn-cv { background: linear-gradient(135deg, var(--bordeaux), #3b0712); color: #ffffff; border: none; }
.btn-cv:hover { background: linear-gradient(135deg, var(--violet), #4c1d95); color: #ffffff; box-shadow: 0 10px 25px rgba(109, 40, 217, 0.25); }
.btn-linkedin { border-color: rgba(10, 102, 194, 0.2); color: #0a66c2; }
.btn-discord { border-color: rgba(88, 101, 242, 0.2); color: #5865f2; }

/* --- RUPTURE ÉDITORIALE 1 : LE BANDEAU ACTUALITÉ (PLEIN ÉCRAN) --- */
.news-section {
    background-color: #4a0b16; /* Fond bordeaux très profond et statutaire */
    color: #fdfcfb;
    padding: 60px 0;
    border-top: 1px solid rgba(250,250,250,0.1);
    border-bottom: 1px solid rgba(250,250,250,0.1);
}
[data-theme="dark"] .news-section { background-color: #121115; }

.news-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 15px; margin-bottom: 20px; }
.news-badge { background: var(--violet); color: #fff; padding: 4px 12px; font-size: 0.75rem; font-weight: 700; border-radius: 4px; letter-spacing: 1px; text-transform: uppercase; }
.news-date { font-size: 0.85rem; color: rgba(255,255,255,0.6); font-weight: 500; }
.news-section h2 { font-size: 1.8rem; font-weight: 700; margin-bottom: 10px; color: #fff; }
.news-section p { font-size: 1.1rem; color: rgba(255,255,255,0.85); max-width: 800px; font-weight: 300; }
.news-subtext { font-size: 0.95rem !important; color: rgba(255,255,255,0.5) !important; margin-top: 10px; font-style: italic; }

/* --- TITRES DE SECTIONS --- */
.section-title { font-size: 1.8rem; font-weight: 800; margin: 90px 0 35px 0; color: var(--text-main); letter-spacing: -0.5px; position: relative; width: fit-content; }
.section-title::after { content: ''; position: absolute; bottom: 0; left: 0; width: 30px; height: 3px; background-color: var(--bordeaux); border-radius: 2px; }

/* --- GRILLE SERVICES (STYLE SAAS CLEAN) --- */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); gap: 30px; }
.card { background-color: var(--card-bg); border: 1px solid var(--border-color); border-radius: 12px; padding: 35px; box-shadow: 0 4px 20px rgba(0,0,0,0.01); transition: all 0.3s ease; position: relative; overflow: hidden; }
.card::before { content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 0; background-color: var(--violet); transition: 0.3s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0,0,0,0.04); border-color: var(--text-main); }
.card:hover::before { height: 100%; }
.card h3 { font-size: 1.3rem; margin-bottom: 12px; font-weight: 700; }
.card p { color: var(--text-muted); font-size: 1rem; line-height: 1.6; }

/* --- GRILLE RÉALISATIONS (PROJETS ASYMÉTRIQUES) --- */
.projects-showcase { display: flex; flex-direction: column; gap: 45px; }
.project-card { display: grid; grid-template-columns: 1fr 1.2fr; background-color: var(--card-bg); border: 1px solid var(--border-color); border-radius: 14px; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,0.02); transition: all 0.3s ease; }
.project-card:hover { border-color: var(--text-main); box-shadow: 0 15px 40px rgba(109, 40, 217, 0.05); }
.project-card.reverse { grid-template-columns: 1.2fr 1fr; }
.project-card.reverse .project-image-wrapper { order: 2; }

.project-image-wrapper { min-height: 260px; overflow: hidden; background: var(--card-hover); border-right: 1px solid var(--border-color); }
.project-card.reverse .project-image-wrapper { border-right: none; border-left: 1px solid var(--border-color); }
.project-thumb { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; filter: saturate(0.8); }
.project-card:hover .project-thumb { transform: scale(1.02); filter: saturate(1.1); }

.project-content { padding: 40px; display: flex; flex-direction: column; justify-content: center; }
.project-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
.project-header h3 { font-size: 1.4rem; font-weight: 700; letter-spacing: -0.3px; }
.project-link { color: var(--text-main); text-decoration: none; font-weight: 600; font-size: 0.9rem; transition: color 0.2s; }
.project-link:hover { color: var(--bordeaux); text-decoration: underline; }
.project-text { color: var(--text-muted); font-size: 0.98rem; margin-bottom: 20px; }

.btn-more { display: inline-flex; align-items: center; color: var(--violet); text-decoration: none; font-weight: 700; font-size: 0.95rem; transition: 0.2s; width: fit-content; }
.btn-more:hover { color: var(--bordeaux); transform: translateX(3px); }

.project-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 15px; }
.mini-tag { background: var(--card-hover); border: 1px solid var(--border-color); padding: 3px 10px; border-radius: 6px; font-size: 0.75rem; font-weight: 600; color: var(--text-muted); }

/* --- BOÎTE À OUTILS --- */
.skills-container { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-tag { background-color: var(--card-bg); border: 1px solid var(--border-color); padding: 8px 18px; border-radius: 8px; font-weight: 600; font-size: 0.9rem; transition: 0.2s; }
.skill-tag:hover { border-color: var(--violet); color: var(--violet); background: var(--card-hover); }

/* --- PARCOURS CV GRILLE --- */
.cv-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 50px; margin-bottom: 40px; }
.cv-item { margin-bottom: 25px; padding-bottom: 20px; border-bottom: 1px dashed var(--border-color); }
.cv-item:last-child { border-bottom: none; }
.cv-item h4 { font-size: 1.2rem; font-weight: 700; color: var(--text-main); }
.cv-item .date-loc { font-size: 0.85rem; color: var(--bordeaux); margin: 3px 0 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.cv-item ul { margin-left: 18px; color: var(--text-muted); font-size: 0.95rem; }
.cv-item ul li { margin-bottom: 5px; }

/* --- PAGE DÉTAILS PROJETS ÉDITORIALE (`projets.html`) --- */
.deep-projects-container { display: flex; flex-direction: column; gap: 60px; }
.detailed-project-block { background: var(--card-bg); border: 1px solid var(--border-color); padding: 50px; border-radius: 16px; box-shadow: 0 4px 30px rgba(0,0,0,0.01); }
.detailed-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border-color); padding-bottom: 20px; }
.detailed-header h2 { font-size: 1.8rem; font-weight: 800; }
.project-meta-strip { display: flex; gap: 20px; margin: 20px 0 35px; font-size: 0.85rem; color: var(--text-muted); background: var(--card-hover); padding: 10px 20px; border-radius: 6px; width: fit-content; border: 1px solid var(--border-color); }
.content-text-zone h3 { font-size: 1.15rem; font-weight: 700; margin: 30px 0 12px; color: var(--bordeaux); text-transform: uppercase; letter-spacing: 0.5px; }
.content-text-zone p { color: var(--text-muted); font-size: 1.05rem; margin-bottom: 16px; text-align: justify; line-height: 1.7; }

/* --- RUPTURE ÉDITORIALE 2 : LE BLOC CONTACT NOIR MAT (PLEIN ÉCRAN) --- */
.contact-section {
    background-color: #121115; /* Devient noir mat pour clore le site */
    color: #f5f5f4;
    padding: 80px 0;
    margin-top: 100px;
    border-top: 1px solid #2e2e2e;
}
.contact-section .section-title { color: #fff; }
.contact-section .section-title::after { background-color: var(--violet); }

.contact-form { max-width: 650px; margin: 0 auto; }
.form-group { margin-bottom: 22px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; font-size: 0.9rem; color: rgba(255,255,255,0.8); }
.form-group input, .form-group textarea { width: 100%; padding: 14px; border: 1px solid #2e2e2e; border-radius: 6px; background-color: #1c1a22; color: #fff; font-size: 1rem; transition: 0.2s; }
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--violet); background-color: #22202a; }

/* --- FOOTER ÉDITORIAL --- */
footer { text-align: center; padding: 40px 20px; color: #a8a29e; background: #0b0a0d; border-top: 1px solid #1f1d24; font-size: 0.9rem; }
footer a { color: var(--violet); text-decoration: none; font-weight: 600; }

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
    header { padding: 80px 0 40px; }
    h1 { font-size: 2.6rem; }
    .project-card, .project-card.reverse { grid-template-columns: 1fr !important; }
    .project-card.reverse .project-image-wrapper { order: 0; }
    .project-image-wrapper { min-height: 200px; border-bottom: 1px solid var(--border-color); border-left: none !important; border-right: none !important; }
    .cv-grid { grid-template-columns: 1fr; gap: 20px; }
    .detailed-project-block { padding: 25px; }
    .detailed-header { flex-direction: column; align-items: flex-start; gap: 10px; }
}


/* ==========================================================================
   --- EXTENSION DU DESIGN : DASHBOARD GAMING ---
   ========================================================================== */

/* Carte Profil Joueur Principale */
.gamer-hero-card {
    display: flex;
    align-items: center;
    gap: 35px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 40px;
    border-radius: 16px;
    margin-top: 20px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.01);
}

.gamer-avatar-wrapper {
    width: 110px;
    height: 110px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid var(--bordeaux);
    box-shadow: 0 0 15px rgba(107, 29, 47, 0.1);
    flex-shrink: 0;
}

.gamer-avatar { width: 100%; height: 100%; object-fit: cover; }

.gamer-identity h1 { font-size: 2.4rem; font-weight: 800; margin: 4px 0; }
.gamer-identity h1 span { color: var(--text-muted); font-size: 1.4rem; font-style: normal; }
.gamer-status-badge { font-size: 0.75rem; font-weight: 700; color: #22c55e; text-transform: uppercase; letter-spacing: 0.5px; }
.gamer-bio { color: var(--text-muted); font-size: 1rem; max-width: 650px; margin-bottom: 15px; }

.gamer-platforms { display: flex; gap: 10px; }
.platform-tag { background-color: var(--card-hover); border: 1px solid var(--border-color); padding: 4px 12px; border-radius: 6px; font-size: 0.8rem; font-weight: 600; }

/* Grille du tableau des scores */
.gaming-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

/* Fiche de statistiques de jeu */
.game-stats-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.game-stats-card:hover {
    transform: translateY(-3px);
    border-color: var(--text-main);
}

/* Bordures supérieures thématiques très fines style SaaS */
.game-stats-card.r6-theme { border-top: 4px solid var(--bordeaux); }
.game-stats-card.marvel-theme { border-top: 4px solid var(--violet); }
.game-stats-card.mh-theme { border-top: 4px solid #eab308; }

.game-card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.game-card-header h3 { font-size: 1.25rem; font-weight: 700; color: var(--text-main); }
.rank-badge { font-size: 0.8rem; font-weight: 700; color: var(--bordeaux); text-transform: uppercase; }

/* Ligne des compteurs numériques style SaaS Metrics */
.stats-counter-row {
    display: flex;
    justify-content: space-between;
    background-color: var(--card-hover);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
}

.stat-counter { display: flex; flex-direction: column; align-items: center; flex: 1; text-align: center; }
.stat-counter:not(:last-child) { border-right: 1px solid var(--border-color); }

.stat-value { font-size: 1.3rem; font-weight: 800; color: var(--text-main); font-family: monospace; }
.stat-label { font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase; font-weight: 600; margin-top: 2px; }

.game-details-box { font-size: 0.92rem; color: var(--text-muted); }
.game-details-box p { margin-bottom: 8px; }
.game-details-box p:last-child { margin-bottom: 0; }

/* Setup lists styling */
.setup-list { list-style: none; margin-left: 0 !important; }
.setup-list li { font-size: 0.95rem; color: var(--text-muted); margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px dashed var(--border-color); }
.setup-list li:last-child { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }
.setup-list strong { color: var(--text-main); }

/* Ajustement Mobile pour la fiche Gamer */
@media (max-width: 768px) {
    .gamer-hero-card { flex-direction: column; text-align: center; padding: 25px; gap: 20px; }
    .gamer-identity h1 { font-size: 2rem; }
    .gamer-platforms { justify-content: center; }
}



/* ==========================================================================
   --- STRUCTURE GENERALE & FIXES POUR LA NAVIGATION ---
   ========================================================================== */

/* Compensation pour la barre de navigation fixe au-dessus du contenu */
header, main.container {
    padding-top: 100px;
}
.hub-header {
    padding-top: 140px;
    padding-bottom: 40px;
}

/* --- BARRE DE NAVIGATION (NAVBAR SAAS) --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--bg-color);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: 15px 0;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.nav-logo {
    font-size: 1.3rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--text-main);
    letter-spacing: -1px;
    flex-shrink: 0;
}
.nav-logo span { color: var(--bordeaux); font-weight: 300; font-style: italic; }

.nav-links {
    display: flex;
    align-items: center;
    gap: 25px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--bordeaux);
}

[data-theme="dark"] .nav-links a:hover, [data-theme="dark"] .nav-links a.active {
    color: var(--violet);
}

.nav-btn-contact {
    padding: 6px 14px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background-color: var(--card-bg);
}
.nav-btn-contact:hover {
    border-color: var(--text-main) !important;
}

/* Repositionnement du bouton thème à l'intérieur de la nav */
#theme-toggle {
    position: static; /* Annule le positionnement fixe précédent */
    padding: 8px 14px;
    font-size: 0.8rem;
    margin: 0;
}

/* --- ADJUSTEMENTS DES CARTES DU HUB --- */
.hub-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 320px;
}
.hub-card h3 {
    margin-top: 10px;
}
.hub-card p {
    margin-bottom: auto;
    padding: 15px 0;
}
.hub-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
}

/* Thématiques discrètes sur le Hub */
.card.pro-theme:hover { border-color: var(--bordeaux); }
.card.gaming-theme:hover { border-color: var(--violet); }

/* --- VRAI FOOTER ÉTENDU --- */
.main-footer {
    background-color: #0b0a0d;
    color: #a8a29e;
    padding: 40px 0;
    border-top: 1px solid #1f1d24;
    font-size: 0.9rem;
    margin-top: 0;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: #f5f5f4;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}
.footer-links a:hover {
    color: var(--violet);
}

/* Responsive mobile pour la barre de navigation */
@media (max-width: 768px) {
    .nav-container { flex-direction: column; text-align: center; gap: 15px; }
    .nav-links { flex-wrap: wrap; justify-content: center; gap: 15px; }
    header, main.container { padding-top: 160px; }
    .footer-container { flex-direction: column; text-align: center; }
}


/* --- CORRECTION ESPACEMENT HUB --- */
/* Annule le padding global du main uniquement lorsqu'il suit le header du Hub */
.hub-header + main.container {
    padding-top: 20px; 
}


/* --- CACHER LE CHAMP ANTI-SPAM (HONEYPOT) --- */
.honeypot-field {
    opacity: 0;
    position: absolute;
    top: -9999px;
    left: -9999px;
    z-index: -1;
}