﻿/* styles.css
   Palette:
   --dark: #001524
   --teal: #15616D
   --cream: #FFECD1
   --orange: #FF7D00
   --brown: #78290F
*/

:root {
    --dark: #001524;
    --teal: #15616D;
    --cream: #FFECD1;
    --orange: #FF7D00;
    --brown: #78290F;
    --max-width: 1100px;
    --radius: 12px;
    --gap: 1.25rem;
    --transition: 200ms ease;
    --fw-heading: 700;
    --fw-body: 400;
}

* {
    box-sizing: border-box
}

html, body {
    height: 100%
}

body {
    padding-top: 72px; /* hauteur approximative du header */
    margin: 0;
    font-family: "Century Gothic", CenturyGothic, AppleGothic, sans-serif;
    background: linear-gradient(180deg, var(--dark) 0%, #002736 100%);
    background-repeat: no-repeat;        /* ne pas répéter le dégradé */
    background-attachment: fixed;       /* optionnel : dégradé fixe lors du scroll */
    background-size: cover;             /* couvre toute la zone visible */
    min-height: 100vh;                  /* assure que le body fasse au moins la hauteur de la fenêtre */
    color: var(--cream);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.45;
    padding-bottom: 3rem;
}



/* Layout container */
.container {
    width: calc(100% - 2rem);
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2rem 0;
}

/* Top navigation */
.site-header {
    position: fixed;       /* reste toujours en haut */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 40;
    background: rgba(0,21,36,0.8); /* légèrement transparent pour voir le fond */
    backdrop-filter: blur(6px);     /* facultatif, pour effet glass */
    padding: 0.75rem 1rem;
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--gap);
    padding: 0.75rem 1rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--cream);
}

    .brand .logo {
        width: 44px;
        height: 44px;
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

.nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
}

    .nav-links a {
        color: var(--cream);
        text-decoration: none;
        padding: 0.45rem 0.6rem;
        border-radius: 8px;
        font-weight: 600;
        transition: var(--transition);
    }

        .nav-links a:hover,
        .nav-links a.active {
            background: rgba(255,236,209,0.06);
            color: var(--orange);
            transform: translateY(-2px);
        }

/* Hero */
.hero {
    padding: 4rem 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: center;
}

.hero-inner {
    display: flex;
    gap: 2rem;
    align-items: center;
    justify-content: space-between;
}

.hero-text h1 {
    margin: 0 0 0.5rem 0;
    font-size: clamp(1.8rem, 4.4vw, 3.2rem);
    font-weight: var(--fw-heading);
    color: var(--cream);
}

.hero-text p {
    margin: 0 0 1rem 0;
    color: rgba(255,236,209,0.9);
    max-width: 60ch;
}

.cta-group {
    display: flex;
    gap: 0.75rem
}

.btn {
    display: inline-block;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    transition: var(--transition);
    cursor: pointer;
}

.btn-primary {
    background: var(--orange);
    color: var(--dark);
    box-shadow: 0 8px 20px rgba(255,125,0,0.12);
}

.btn-ghost {
    background: transparent;
    border: 1px solid rgba(255,236,209,0.08);
    color: var(--cream);
}

.hero-visual {
    min-width: 260px;
    width: 40%;
    max-width: 420px;
    aspect-ratio: 4/3;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(21,97,109,0.12), rgba(120,41,15,0.06));
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,236,209,0.85);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* Sections */
.section {
    margin-top: 2rem;
    padding: 2rem 0;
    background: linear-gradient(180deg, rgba(0,21,36,0.02), transparent);
    border-radius: var(--radius);
}

/* Gallery (Mes Créations) */
.gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 colonnes fixes */
    gap: 1rem;
}


.card {
    background: linear-gradient(180deg, rgba(255,236,209,0.03), rgba(255,236,209,0.01));
    border-radius: 12px;
    overflow: hidden;
    padding: 0.6rem;
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
}

    .card:hover {
        transform: translateY(-6px);
        box-shadow: 0 12px 30px rgba(0,0,0,0.5);
    }

	.card .thumb {
	    background: rgba(0,0,0,0.25);
    	aspect-ratio: 4 / 3;
	    width: 100%;
	    border-radius: 10px;
	    margin-bottom: 0.6rem;
	    background-size: cover;
	    background-position: center;
	}


    .card h3 {
        margin: 0 0 0.4rem 0;
        font-size: 1.05rem
        text-decoration: none;
    }

    .card p {
        margin: 0;
        color: rgba(255,236,209,0.75);
        font-size: 0.92rem
        text-decoration: none;
    }

/* About */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 1.25rem;
    align-items: start;
}

.profile {
    padding: 1rem;
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(21,97,109,0.03), rgba(120,41,15,0.02));
}

.bio {
    font-size: 0.98rem;
    color: rgba(255,236,209,0.92);
}

/* Footer */
.site-footer {
    margin-top: 2.5rem;
    padding: 1.25rem 0;
    text-align: center;
    color: rgba(255,236,209,0.65);
    font-size: 0.95rem;
}

/* Responsive */
@media (max-width:900px) {
    .hero-inner {
        flex-direction: column-reverse;
        align-items: flex-start
    }

    .hero-visual {
        width: 100%
    }

    .about-grid {
        grid-template-columns: 1fr
    }

    .nav-links {
        display: none
    }
    /* keep it minimal; you can add a burger menu later */
}

.contact-section {
    max-width: 600px;
    margin: 0 auto;
}


form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}


.field {
    display: flex;
    flex-direction: column;
}


label {
    margin-bottom: 0.25rem;
    font-weight: 600;
}


input, textarea {
    padding: 0.6rem;
    border-radius: 8px;
    border: 1px solid rgba(255,236,209,0.15);
    background: rgba(0,0,0,0.25);
    color: var(--cream);
}


    input:focus, textarea:focus {
        outline: none;
        border-color: var(--orange);
    }


#formStatus {
    min-height: 1.2em;
    font-size: 0.95rem;
}

/* === Page transitions === */


.page-transition {
    display: none;
}


body.is-transitioning .page-transition {
    transform: translateY(0);
}


.page-transition {
    transition: transform 0.6s cubic-bezier(.77,0,.18,1);
}


body.fade-in {
    animation: fadeIn 0.6s ease both;
}


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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================= */
/* Harmonisation du header       */
/* ============================= */

/* Hauteur fixe et cohérente du header */
.site-header {
    min-height: 72px;
    display: flex;
    align-items: center;
}

/* La navbar prend toute la hauteur du header */
.navbar {
    min-height: 72px;
    padding: 0 1rem;
}

/* Forcer une structure verticale stable pour la marque */
.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    line-height: 1;
}

/* Uniformiser tous les textes dans le brand */
.brand strong,
.brand div,
.brand small {
    line-height: 1.1;
    margin: 0;
    padding: 0;
    display: block;
}

/* Sécurise la taille du logo (déjà bon mais on verrouille) */
.brand .logo {
    flex-shrink: 0;
}

/* Évite que le nav fasse varier la hauteur */
.nav-links {
    height: 100%;
    display: flex;
    align-items: center;
}

/* Uniformise les liens */
.nav-links a {
    line-height: 1;
}

/* === Article content === */

.article-content img {
    max-width: 100%;
    max-height: 520px;
    width: auto;
    height: auto;
    display: block;
    margin: 1.25rem auto;
    border-radius: 12px;
    object-fit: contain;
}

.gallery a.card {
    color: inherit;              /* même couleur que le texte normal */
    text-decoration: none;       /* pas de soulignement */
}

.gallery a.card * {
    color: inherit;              /* enfants (h3, p, etc.) */
    text-decoration: none;
}

/* Burger menu */
.burger {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 28px;
    height: 22px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

    .burger span {
        display: block;
        height: 3px;
        background: var(--cream);
        border-radius: 2px;
        transition: 0.3s;
    }

/* mobile nav */
.nav-links {
    display: flex;
    gap: 1rem;
}

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

    .burger {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 72px;
        right: 0;
        background: rgba(0,21,36,0.95);
        flex-direction: column;
        width: 220px;
        padding: 1rem;
        gap: 1rem;
        display: none;
    }

        .nav-links.open {
            display: flex;
        }

        .nav-links a {
            padding: 0.6rem 1rem;
            border-radius: 8px;
        }

    .brand .logo img {
        max-width: 36px;
        height: auto;
    }

    .brand div {
        font-size: 0.85rem;
    }

    .article-wrapper {
        padding: 1rem;
    }

        .article-wrapper h1 {
            font-size: 1.8rem;
        }
}

/* animation burger transform (optionnel) */
.burger.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px,5px);
}

.burger.open span:nth-child(2) {
    opacity: 0;
}

.burger.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px,-5px);
}

/* ============================= */
/* Home / About improvements     */
/* ============================= */

.hero-about {
    padding-top: 5rem;
}

.intro-big {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.intro-small {
    opacity: 0.9;
    font-size: 0.95rem;
}

/* photo principale */
.about-photo {
    background-image: url('about_me_photo.jpg');
    border: 2px dashed rgba(255,236,209,0.15);
    background-size: contain;
    background-repeat: no-repeat;

}

/* skills */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 1rem;
    margin-top: 1rem;
}

.skill-card {
    padding: 1.25rem;
    border-radius: 12px;
    background: rgba(255,236,209,0.03);
    transition: 0.25s;
}

    .skill-card:hover {
        transform: translateY(-4px);
        background: rgba(255,236,209,0.06);
    }

    .skill-card h3 {
        margin-top: 0;
        color: var(--orange);
    }

/* about */
.about-side-visual {
    aspect-ratio: 1/1;
    border-radius: 16px;
    background: rgba(255,236,209,0.05);
    border: 2px dashed rgba(255,236,209,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

/* responsive */
@media (max-width:900px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* images sous skill cards */

.skill-images {
    width: 90%;
    margin-top: 0.9rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
}

    .skill-images img {
        width: 100%;
        aspect-ratio: 1 / 1; /* carrées */
        object-fit: cover; /* crop propre */
        border-radius: 10px;
        transition: transform 0.25s ease, opacity 0.25s ease;
    }

        /* petit effet premium */
        .skill-images img:hover {
            transform: scale(1.05);
            opacity: 0.95;
        }
