/*
* Projet.css - Page de détail des projets du Portfolio MMI
* Palette: Vieux rose (#C8A2A5), Charbon (#2A2729), Crème (#FEF6ED)
*/

/* === IMPORT DE BASE === */
@import url('https://fonts.googleapis.com/css2?family=League+Gothic&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Glacial+Indifference:wght@400;700&display=swap');

/* === RESET & BASE === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

:root {
    --vieux-rose: #C8A2A5;
    --vieux-rose-dark: #A88285;
    --vieux-rose-light: #DBBBBD;
    --charbon: #2A2729;
    --charbon-light: #403C3F;
    --creme: #FEF6ED;
    --creme-dark: #F0E8DF;
    --white: rgba(255, 255, 255, 0.7);
    --gray: #6D6366;
    --noir: #000000;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--white);
    color: var(--charbon);
    line-height: 1.6;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

/* === TYPOGRAPHY === */
h1, h2, h3, h4, h5, h6 {
    font-family: 'League Gothic', Impact, sans-serif;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2rem;
    margin-bottom: 1.2rem;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -10px;
    width: 40px;
    height: 3px;
    background-color: var(--vieux-rose);
    transition: var(--transition);
}

h2:hover::after {
    width: 100%;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

a {
    color: var(--charbon);
    text-decoration: none;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    transition: var(--transition);
}

a:hover {
    color: var(--vieux-rose-dark);
}

/* === LAYOUT === */
.container {
    width: 80%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
}

section {
    padding: 4rem 5%;
}

main {
    min-height: 70vh;
    padding: 2rem 0;
}

/* === PROJECT HEADER === */
.project-header {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
    background-color: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.header-image {
    height: 500px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.1) 100%);
}

.header-content {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.project-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--vieux-rose);
    color: var(--white);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 500;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    margin-bottom: 1.5rem;
    align-self: flex-start;
}

.project-subtitle {
    color: var(--gray);
    font-size: 1.2rem;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    margin-bottom: 2rem;
}

.project-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--creme-dark);
}

.meta-item {
    display: flex;
    flex-direction: column;
}

.meta-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gray);
    font-family: 'Glacial Indifference', Arial, sans-serif;
    margin-bottom: 0.5rem;
}

.meta-value {
    font-weight: 600;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

.header-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    background-color: var(--creme);
    border-radius: 20px;
    font-size: 0.85rem;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

/* Classe spécifique à chaque catégorie */
.dev-project .project-badge {
    background-color: var(--vieux-rose);
}

.com-project .project-badge {
    background-color: #6a8caf;
}

.av-project .project-badge {
    background-color: #8e7fad;
}

/* === PROJECT CONTENT === */
.project-container {
    background-color: var(--white);
    border-radius: 12px;
    padding: 3rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.project-description h2 {
    margin-top: 2.5rem;
}

.project-description p {
    line-height: 1.8;
    font-size: 1.05rem;
    color: var(--charbon-light);
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

.project-skills {
    margin: 3rem 0;
}

.skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.5rem;
}

.skill-item {
    padding: 0.7rem 1.2rem;
    background-color: var(--creme);
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    transition: var(--transition);
}

.skill-item:hover {
    background-color: var(--vieux-rose-light);
    transform: translateY(-3px);
}

/* === GALLERY === */
.project-gallery {
    margin: 3rem 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    transition: var(--transition);
    position: relative;
}

.gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.1);
    opacity: 0;
    transition: var(--transition);
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.gallery-item:hover::after {
    opacity: 1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* === PROJECT LINKS === */
.project-links-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--creme-dark);
}

.links-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background-color: var(--charbon);
    color: var(--white);
    border-radius: 4px;
    font-weight: 500;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    text-align: center;
    transition: var(--transition);
    border: 2px solid var(--charbon);
    cursor: pointer;
}

.btn:hover {
    background-color: transparent;
    color: var(--charbon);
}

.back-btn {
    background-color: var(--vieux-rose);
    border-color: var(--vieux-rose);
    color: var(--white);
}

.back-btn:hover {
    background-color: transparent;
    color: var(--vieux-rose-dark);
    border-color: var(--vieux-rose-dark);
}

/* === LIGHTBOX === */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: -40px;
    color: var(--white);
    font-size: 2rem;
    cursor: pointer;
    z-index: 2001;
    transition: transform 0.3s ease;
}

.lightbox-close:hover {
    transform: scale(1.2);
}

#lightbox-img {
    max-width: 100%;
    max-height: 85vh;
    display: block;
    margin: 0 auto;
    border-radius: 5px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.3);
}

.lightbox-nav {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1.5rem;
}

.lightbox-prev,
.lightbox-next {
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background-color: var(--vieux-rose);
    transform: scale(1.1);
}

/* === RESPONSIVE === */
@media (max-width: 992px) {
    .project-header {
        grid-template-columns: 1fr;
    }

    .header-image {
        height: 300px;
    }

    .project-meta {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2.2rem;
    }

    h2 {
        font-size: 1.8rem;
    }

    .container {
        width: 90%;
        padding: 0 20px;
    }

    .project-container {
        padding: 2rem;
    }

    .header-content {
        padding: 2rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

@media (max-width: 576px) {
    h1 {
        font-size: 1.8rem;
    }

    .project-meta {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .project-container {
        padding: 1.5rem;
    }

    .lightbox-close {
        top: -30px;
        right: 0;
    }

    .skill-item {
        font-size: 0.8rem;
        padding: 0.6rem 1rem;
    }
}

/* Style spécifique pour les boutons de navigation entre projets */
.project-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3rem;
}

.nav-project {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.2rem;
    border-radius: 8px;
    transition: var(--transition);
    background-color: var(--charbon-light);
    color: var(--white);
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

.nav-project:hover {
    background-color: var(--vieux-rose);
    color: var(--white);
    transform: translateY(-3px);
}

.nav-prev {
    padding-left: 0.6rem;
}

.nav-next {
    padding-right: 0.6rem;
}
.project-video {
    margin: 2rem 0;
}

.video-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* Ratio 16:9 */
    margin: 1rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    margin-top: 1rem;
    transition: color 0.3s ease;
}

.video-link:hover {
    color: #0056b3;
}

.video-icon {
    width: 18px;
    height: 18px;
}
/* === PDF VIEWER STYLES === */
/* À ajouter à la fin de projet.css */

.pdf-viewer-container {
    margin: 3rem 0;
    background-color: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--creme-dark);
}

.pdf-header {
    background: linear-gradient(135deg, var(--vieux-rose) 0%, var(--vieux-rose-dark) 100%);
    color: var(--white);
    padding: 2rem 0;
    text-align: center;
    position: relative;
}

.pdf-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" patternUnits="userSpaceOnUse" width="100" height="100"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.15"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
}

.pdf-header h1 {
    margin: 0;
    font-size: 2.2rem;
    font-family: 'League Gothic', Impact, sans-serif;
    letter-spacing: 2px;
    position: relative;
    z-index: 1;
}

.pdf-header p {
    margin: 0.5rem 0 0 0;
    font-size: 1.1rem;
    opacity: 0.9;
    font-family: 'Glacial Indifference', Arial, sans-serif;
    position: relative;
    z-index: 1;
}

.pdf-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background-color: var(--creme);
    border-bottom: 1px solid var(--creme-dark);
    flex-wrap: wrap;
    gap: 1rem;
}

.pdf-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.pdf-icon {
    background-color: var(--vieux-rose);
    color: var(--white);
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
    font-family: 'League Gothic', Impact, sans-serif;
    letter-spacing: 1px;
}

.pdf-details h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--charbon);
    font-family: 'Glacial Indifference', Arial, sans-serif;
    font-weight: 600;
}

.pdf-details p {
    margin: 0.2rem 0 0 0;
    color: var(--gray);
    font-size: 0.9rem;
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

.pdf-actions {
    display: flex;
    gap: 0.8rem;
    align-items: center;
}

.btn-primary {
    background-color: var(--charbon);
    color: var(--white);
    border: 2px solid var(--charbon);
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--charbon);
}

.btn-secondary {
    background-color: transparent;
    color: var(--charbon);
    border: 2px solid var(--charbon-light);
}

.btn-secondary:hover {
    background-color: var(--charbon-light);
    color: var(--white);
    border-color: var(--charbon-light);
}

.pdf-viewer-frame {
    position: relative;
    width: 100%;
    min-height: 800px;
    background-color: var(--creme-dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-embed {
    width: 100%;
    height: 800px;
    border: none;
    background-color: var(--white);
    border-radius: 0;
    transition: var(--transition);
}

.pdf-embed:fullscreen {
    height: 100vh;
    border-radius: 0;
}

.pdf-fallback {
    text-align: center;
    padding: 3rem;
    color: var(--charbon);
}

.pdf-fallback h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--vieux-rose-dark);
    font-family: 'League Gothic', Impact, sans-serif;
}

.pdf-fallback p {
    margin-bottom: 2rem;
    color: var(--gray);
    font-family: 'Glacial Indifference', Arial, sans-serif;
}

/* États de chargement */
.pdf-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: var(--gray);
}

.pdf-loading::before {
    content: '';
    width: 40px;
    height: 40px;
    border: 3px solid var(--creme-dark);
    border-top: 3px solid var(--vieux-rose);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Améliorations responsive */
@media (max-width: 992px) {
    .pdf-controls {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }

    .pdf-info {
        justify-content: center;
        margin-bottom: 1rem;
    }

    .pdf-actions {
        justify-content: center;
    }

    .pdf-embed {
        height: 700px;
    }

    .pdf-viewer-frame {
        min-height: 700px;
    }
}

@media (max-width: 768px) {
    .pdf-header {
        padding: 1.5rem 0;
    }

    .pdf-header h1 {
        font-size: 1.8rem;
    }

    .pdf-header p {
        font-size: 1rem;
    }

    .pdf-controls {
        padding: 1rem;
    }

    .pdf-info {
        flex-direction: column;
        text-align: center;
        gap: 0.8rem;
    }

    .pdf-details h3 {
        font-size: 1rem;
    }

    .pdf-embed {
        height: 600px;
    }

    .pdf-viewer-frame {
        min-height: 600px;
    }

    .pdf-fallback {
        padding: 2rem 1rem;
    }
}

@media (max-width: 576px) {
    .pdf-header h1 {
        font-size: 1.5rem;
        line-height: 1.2;
    }

    .pdf-header p {
        font-size: 0.9rem;
        padding: 0 1rem;
    }

    .pdf-controls {
        padding: 0.8rem;
        gap: 0.8rem;
    }

    .pdf-actions {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .pdf-embed {
        height: 500px;
    }

    .pdf-viewer-frame {
        min-height: 500px;
    }
}

/* Animations et transitions */
.pdf-viewer-container {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Effets hover pour les boutons */
.pdf-controls .btn {
    position: relative;
    overflow: hidden;
}

.pdf-controls .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.pdf-controls .btn:hover::before {
    left: 100%;
}

/* Style pour le mode plein écran */
.pdf-embed:fullscreen {
    width: 100vw;
    height: 100vh;
    object-fit: contain;
}

/* Accessibilité */
.pdf-controls .btn:focus {
    outline: 2px solid var(--vieux-rose);
    outline-offset: 2px;
}

.pdf-embed:focus {
    outline: 2px solid var(--vieux-rose);
    outline-offset: -2px;
}

/* Dark mode support (optionnel) */
@media (prefers-color-scheme: dark) {
    .pdf-viewer-container {
        background-color: var(--charbon);
        border-color: var(--charbon-light);
    }

    .pdf-controls {
        background-color: var(--charbon-light);
        border-color: var(--charbon);
    }

    .pdf-details h3 {
        color: var(--creme);
    }

    .pdf-fallback {
        color: var(--creme);
    }

    .pdf-fallback h3 {
        color: var(--vieux-rose-light);
    }
}