/* --- 1. VARIABLES & BASES --- */
:root {
    --primary: #00d2ff;
    --dark: #1a1a2e;
    --white: #ffffff;
    --light-bg: #f4f7f6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body, html {
    font-family: 'Poppins', sans-serif;
    background-color: var(--light-bg);
    color: #333;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ===== STYLES MODE JOUR/NUIT ===== */
.theme-toggle {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 18px;
    transition: all 0.3s ease;
    margin-left: 20px;
}

.theme-toggle:hover {
    background: #2563eb;
    transform: scale(1.05);
}

/* Mode sombre */
body.dark-mode {
    background-color: #0f172a;
    color: #e2e8f0;
}

body.dark-mode .top-nav {
    background-color: #1e293b;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

body.dark-mode .nav-links a {
    color: #e2e8f0;
}

body.dark-mode .nav-links a:hover {
    color: var(--primary);
}

body.dark-mode .column-title {
    color: #e2e8f0;
}

body.dark-mode .card {
    background-color: #1e293b;
    color: #e2e8f0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

body.dark-mode .card:hover {
    box-shadow: 0 15px 35px rgba(0, 210, 255, 0.4);
}

body.dark-mode .skills-list li {
    color: #cbd5e1;
    border-bottom-color: #334155;
}

body.dark-mode .skills-list li::before {
    color: var(--primary);
}

body.dark-mode .certif-link {
    background: rgba(0, 210, 255, 0.15);
    color: #e2e8f0;
    border-color: #334155;
}

body.dark-mode .certif-link:hover {
    background: var(--primary);
    color: #1e293b;
    border-color: var(--primary);
}

body.dark-mode footer {
    background-color: #1e293b;
    color: #94a3b8;
}

/* ===== FIN STYLES MODE JOUR/NUIT ===== */

/* --- 2. NAVIGATION --- */
.top-nav {
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 0 5vw; 
    background: var(--dark); 
    height: 10vh;
    z-index: 1000;
    transition: background-color 0.3s ease;
}

.nav-links { 
    display: flex; 
    gap: 20px;
    align-items: center;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: 0.3s;
}

.nav-links a:hover { color: var(--primary); }
.icon { height: 7vh; width: auto; }

/* --- 3. CONTENU (CENTRAGE VERTICAL ET HORIZONTAL) --- */
.content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3vw;
    height: 85vh;
    padding: 0 5vw;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.column {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.column-title {
    text-align: center;
    color: var(--dark);
    font-size: 1.3rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.3s ease;
}

/* --- 4. LES CARTES --- */
.card {
    background: var(--white);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border-top: 6px solid var(--primary);
    text-align: center;
    transition: all 0.3s ease;
    min-height: 350px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0, 210, 255, 0.2);
}

.card-logo {
    height: 60px;
    margin-bottom: 10px;
}

/* --- 5. LISTE DES COMPÉTENCES --- */
.skills-list {
    list-style: none;
    width: 100%;
    text-align: left;
    margin-top: 10px;
}

.skills-list li {
    padding: 8px 0;
    font-size: 0.95rem;
    color: #555;
    border-bottom: 1px solid #eee;
    position: relative;
    padding-left: 20px;
    transition: color 0.3s ease, border-bottom-color 0.3s ease;
}

.skills-list li::before {
    content: "▹";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

.skills-list li:last-child {
    border-bottom: none;
}

.certif-container {
    display: flex;
    flex-direction: column;
    gap: 3px;
    width: 100%;
}

.certif-row {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.certif-link {
    text-decoration: none;
    background: rgba(0, 210, 255, 0.1);
    color: var(--dark);
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #eee;
    transition: 0.3s;
    flex: 1;
    text-align: center;
}

.certif-link:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* --- 6. FOOTER --- */
footer {
    background: var(--dark);
    color: white;
    text-align: center;
    height: 5vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* --- ANIMATIONS --- */
.fade-in {
    animation: fadeInAnim 0.8s ease-out forwards;
}

@keyframes fadeInAnim {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .content {
        grid-template-columns: 1fr;
        height: auto;
        padding: 50px 5vw;
        overflow-y: auto;
    }
    body, html { overflow-y: auto; }
}