/* ===== VARIABLES ===== */
:root {
    --primary: #2c3e50;
    --accent: #3498db;
    --accent-light: #d6eaf8;
    --text: #2c3e50;
    --text-light: #7f8c8d;
    --bg: #f4f6f8;
    --white: #ffffff;
    --border: #dde1e7;
    --footer-bg: #ecf0f1;
    --nav-hover: #2980b9;
    --font-main: 'Raleway', sans-serif;
    --font-body: 'Source Serif 4', serif;
}

/* ===== RESET ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

/* ===== HEADER ===== */
header {
    background-color: var(--white);
    border-bottom: 2px solid var(--border);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header h1 {
    font-family: var(--font-main);
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    color: var(--primary);
}

/* ===== NAVIGATION ===== */
nav {
    background-color: var(--white);
    border-bottom: 1px solid var(--border);
}

nav ul {
    list-style: none;
    display: flex;
    padding: 0 2rem;
}

nav ul li a {
    display: block;
    padding: 0.75rem 1.2rem;
    font-family: var(--font-main);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-light);
    transition: color 0.2s;
}

nav ul li a:hover {
    color: var(--accent);
}

nav ul li a.active {
    color: var(--white);
    background-color: var(--accent);
}

/* ===== BURGER BUTTON ===== */
.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
}

.burger span {
    display: block;
    width: 26px;
    height: 3px;
    background-color: var(--primary);
    border-radius: 2px;
    transition: all 0.3s;
}

/* ===== MAIN ===== */
main {
    flex: 1;
    padding: 2rem;
    max-width: 1100px;
    width: 100%;
    margin: 0 auto;
}

/* ===== FOOTER ===== */
footer {
    background-color: var(--footer-bg);
    border-top: 1px solid var(--border);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

footer p {
    font-size: 0.85rem;
    color: var(--text-light);
}

.social-links {
    display: flex;
    gap: 0.6rem;
    align-items: center;
}

.social-links span {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-right: 0.3rem;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: var(--primary);
    color: var(--white);
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    transition: background-color 0.2s;
}

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

/* ===== PAGE: MON CV ===== */
.cv-grid {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 2rem;
    align-items: start;
}

.cv-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.cv-photo {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--accent);
}

.cv-photo-placeholder {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background-color: var(--accent-light);
    border: 3px solid var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.skills-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.skill-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--accent-light);
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent);
    flex-shrink: 0;
}

.skill-bar-wrapper {
    flex: 1;
    background-color: var(--border);
    border-radius: 4px;
    height: 10px;
    overflow: hidden;
}

.skill-bar {
    height: 100%;
    background-color: var(--accent);
    border-radius: 4px;
}

.cv-content h2 {
    font-family: var(--font-main);
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 0.4rem;
    color: var(--primary);
}

.cv-content .subtitle {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 1.2rem;
}

.cv-content p {
    font-size: 0.95rem;
    line-height: 1.75;
    margin-bottom: 1rem;
    color: var(--text);
}

/* ===== PAGE: FORMATION & EXPERIENCE ===== */
.page-title {
    font-family: var(--font-main);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--accent);
}

.timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.timeline-item {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border);
    align-items: start;
}

.timeline-item:last-child {
    border-bottom: none;
}

.timeline-date {
    font-family: var(--font-main);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--accent);
    padding-top: 0.1rem;
}

.timeline-desc {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text);
}

/* ===== PAGE: CONTACT ===== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

fieldset {
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 1.25rem;
}

legend {
    font-family: var(--font-main);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-light);
    padding: 0 0.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.6rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text);
    background-color: var(--white);
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.form-group textarea {
    resize: vertical;
    min-height: 110px;
}

.form-submit {
    text-align: right;
}

.btn {
    background-color: var(--primary);
    color: var(--white);
    border: none;
    padding: 0.55rem 1.2rem;
    font-family: var(--font-main);
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn:hover {
    background-color: var(--accent);
}

.contact-info h3 {
    font-family: var(--font-main);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--primary);
}

.contact-info p {
    font-size: 0.92rem;
    line-height: 1.75;
    color: var(--text);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {

    header {
        padding: 0.9rem 1.2rem;
    }

    .burger {
        display: flex;
    }

    nav ul {
        display: none;
        flex-direction: column;
        padding: 0;
    }

    nav ul.open {
        display: flex;
    }

    nav ul li a {
        padding: 0.9rem 1.2rem;
        border-bottom: 1px solid var(--border);
    }

    nav ul li a.active {
        border-bottom-color: var(--accent);
    }

    main {
        padding: 1.2rem;
    }

    .cv-grid {
        grid-template-columns: 1fr;
    }

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

    .cv-photo-placeholder {
        width: 130px;
        height: 130px;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .timeline-item {
        grid-template-columns: 1fr;
        gap: 0.3rem;
    }

    .timeline-date {
        font-size: 0.85rem;
    }

    footer {
        flex-direction: column;
        align-items: flex-start;
        padding: 1rem 1.2rem;
    }
}
