* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    color: #333;
    line-height: 1.6;
    background-color: #fff;
}

/* Styles pour le menu mobile */
.mobile-menu-toggle {
    display: none;
}

/* Styles responsifs pour les différentes tailles d'écran */
@media (max-width: 1200px) {
    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 900px) {
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
    }
    
    .portfolio-title {
        font-size: 1.6rem !important;
    }
    
    footer {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
}

@media (max-width: 600px) {
    /* Layout pour mobile */
    .portfolio-grid {
        grid-template-columns: 1fr !important;
        padding: 10px;
    }
    
    .album-title {
        font-size: 1.8rem;
        text-align: center;
    }
    
    .album-header {
        flex-direction: column;
        align-items: center;
        gap: 10px;
        padding: 15px 10px;
    }
    
    .portfolio-item {
        height: 220px !important;
    }
    
    /* Navigation mobile */
    /* .navbar {
        padding: 10px;
    } */
    
    .profile-img img {
        width: 40px;
        height: 40px;
    }
    
    .profile-info p {
        font-size: 14px;
    }
    
    .mobile-menu-toggle {
        display: block;
        cursor: pointer;
        z-index: 100;
        margin-left: auto;
    }
    
    .bar {
        display: block;
        width: 25px;
        height: 3px;
        margin: 5px auto;
        background-color: white;
        transition: 0.3s;
    }
    
    .mobile-menu-toggle.active .bar:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }
    
    .mobile-menu-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active .bar:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }
    
    /* .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background-color: rgba(0, 0, 0, 0.9);
        flex-direction: column;
        align-items: center;
        padding: 20px;
        display: none;
        gap: 15px;
        z-index: 99;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-link {
        padding: 10px 0;
        width: 100%;
        text-align: center;
    } */
}

/* Header & Navigation */
header {
    padding: 30px 50px;
    position: fixed;
    width: 100%;
    z-index: 100;
    background-color: rgba(17, 8, 8, 0.95);
    transition: padding 0.3s ease;
}

header.scrolled {
    padding: 15px 50px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2rem;
    font-weight: 400;
    letter-spacing: 3px;
    color: #f7f0f0;
    text-decoration: none;
}

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

.nav-links a {
    margin-left: 40px;
    text-decoration: none;
    color: #e9e0e0;
    font-size: 0.95rem;
    letter-spacing: 1px;
    position: relative;
    font-weight: 300;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -4px;
    left: 0;
    background-color: #e9e0e0;
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Hero Section */
.hero {
    height: 100vh;
    background-image: url('photos/apremont/IMG20220807181956.jpg');
    background-size: cover;
    background-position: top center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
}

.hero-content {
    text-align: center;
    color: #f6f2f2;
    position: relative;
    z-index: 1;
}

.hero-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 5rem;
    font-weight: 300;
    letter-spacing: 10px;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.hero-subtitle {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2rem;
    letter-spacing: 5px;
    font-weight: 300;
    margin-bottom: 30px;
    text-transform: uppercase;
}

.btn {
    display: inline-block;
    padding: 10px 30px;
    border: 1px solid #fff;
    background-color: transparent;
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    letter-spacing: 2px;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Social Links in Hero */
.social-container {
    margin-top: 20px;
}

.social-link-hero {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: #fff;
    padding: 8px 20px;
    border: 1px solid #fff;
    transition: all 0.3s ease;
    font-size: 0.85rem;
    letter-spacing: 1px;
}

.social-link-hero:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.insta-icon {
    margin-right: 10px;
}

/* Portfolio Grid */
.portfolio-section {
    padding: 120px 80px;
    display: none;
    background-color: #141313;
}

.portfolio-section.active {
    display: block;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    background-color: #141313;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    height: 500px;
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.portfolio-item:hover .portfolio-image {
    transform: scale(1.05);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(6, 6, 6, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.5s ease;
}

.portfolio-title {
    font-family: 'Cormorant Garamond', serif;
    color: #fff;
    font-size: 2.5rem;
    letter-spacing: 3px;
    font-weight: 300;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.portfolio-btn {
    font-size: 0.8rem;
    padding: 8px 25px;
}

/* Profile section */
.profile {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.profile-img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    overflow: hidden;
}

.profile-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.username {
    font-weight: bold;
    color: #f7f0f0;
    font-size: 1.2rem;
}

/* Home Page */
.home-page {
    display: block;
}

.home-page.hidden {
    display: none;
}

/* About Page */
.about-page {
    padding: 120px 80px;
    display: none;
}

.about-page.active {
    display: block;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 3rem;
    font-weight: 300;
    margin-bottom: 30px;
    text-align: center;
    letter-spacing: 3px;
}

.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 30px;
}

/* Contact Page */
.contact-page {
    padding: 120px 80px;
    display: none;
}

.contact-page.active {
    display: block;
}

.contact-content {
    max-width: 800px;
    margin: 0 auto;
}

.contact-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 3rem;
    font-weight: 300;
    margin-bottom: 30px;
    text-align: center;
    letter-spacing: 3px;
}

.contact-form {
    display: grid;
    gap: 20px;
}

.form-group {
    display: grid;
    gap: 5px;
}

.form-label {
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.form-input, .form-textarea {
    padding: 10px;
    border: 1px solid #ddd;
    background-color: #f9f9f9;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
}

.form-textarea {
    height: 150px;
    resize: vertical;
}

.form-button {
    justify-self: start;
    padding: 12px 40px;
    border: none;
    background-color: #333;
    color: #fff;
    font-size: 0.9rem;
    letter-spacing: 2px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.form-button:hover {
    background-color: #555;
}

/* Album Page */
.album-page {
    padding: 120px 80px 80px;
    display: none;
}

.album-page.active {
    display: block;
}

.album-header {
    margin-bottom: 40px;
    /*display: flex;*/
    /*align-items: center;*/
}

.back-to-portfolio {
    text-decoration: none;
    color: #333;
    font-size: 1rem;
    margin-right: 20px;
    transition: color 0.3s ease;
}

.back-to-portfolio:hover {
    color: #777;
}

.album-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 2px;
    margin: 0;
}

.album-description {
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.1rem;
    line-height: 1.6;
}

.album-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.album-photo {
    position: relative;
    height: 300px;
    overflow: hidden;
    cursor: pointer;
}

.album-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.album-photo:hover img {
    transform: scale(1.05);
}

.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    padding: 20px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.album-photo:hover .photo-overlay {
    transform: translateY(0);
}

.photo-title {
    color: #fff;
    margin: 0;
    font-size: 1rem;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    opacity: 1;
    pointer-events: auto;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    touch-action: pan-y; /* Autorise le scroll vertical mais pas horizontal */
}

.lightbox-img {
    max-width: 100%;
    max-height: 90vh;
    border: 2px solid #fff;
    user-select: none;
}

.lightbox-caption {
    position: absolute;
    bottom: -40px;
    left: 0;
    width: 100%;
    text-align: center;
    color: #fff;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    background: none;
    border: none;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    background: none;
    border: none;
    padding: 10px;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

/* Footer */
footer {
    padding: 50px;
    background-color: #141313;
    text-align: center;
}

.footer-text {
    font-size: 0.9rem;
    color: #cbc7c7;
}

.social-links {
    margin-top: 20px;
}

.social-link {
    display: inline-block;
    text-decoration: none;
    color: #cbc7c7;
    padding: 8px 20px;
    border: 1px solid #555;
    transition: all 0.3s ease;
    font-size: 0.85rem;
    letter-spacing: 1px;
    margin: 0 5px;
}

.social-link:hover {
    background-color: #555;
    color: #fff;
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
}

.bar {
    height: 3px;
    width: 100%;
    background-color: #fff;
    border-radius: 1px;
}

/* Media Queries */
@media (max-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-title {
        font-size: 4rem;
    }
}

@media (max-width: 768px) {
    header {
        padding: 20px 30px;
    }
    
    header.scrolled {
        padding: 10px 30px;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: rgba(17, 8, 8, 0.95);
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.3s ease;
    }
    
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }
    
    .nav-links a {
        margin: 15px 0;
        font-size: 1rem;
    }
    
    .hero-title {
        font-size: 3rem;
        letter-spacing: 6px;
    }
    
    .hero-subtitle {
        font-size: 1.5rem;
        letter-spacing: 3px;
    }
    
    .portfolio-section, .about-page, .contact-page, .album-page {
        padding: 100px 30px;
    }
}

@media (max-width: 640px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-item {
        height: 400px;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
        letter-spacing: 4px;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
        letter-spacing: 2px;
    }
    
    .album-header {
        /*flex-direction: column;*/
        /*align-items: flex-start;*/
        margin-bottom: 40px;
    }
    
    .back-to-portfolio {
        margin-bottom: 15px;
    }


}

/* Ajout de styles pour corriger le problème de la bannière qui masque le bouton de retour */
.album-page.active {
    padding-top: 150px; /* Augmenté pour compenser la hauteur de la bannière */
}

.album-header {
    margin-bottom: 40px; /* Maintien de la marge existante */
}

.portfolio-section.active {
    padding-top: 150px;
}

/* S'assurer que le bouton de retour est bien visible */
.back-link {
    display: inline-block;
    margin-bottom: 20px;
    color: #cbc7c7;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 1.1rem;
}

.back-link:hover {
    color: #fff;
}

.secteur-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.secteur-card {
    position: relative;
    height: 300px;
    overflow: hidden;
    cursor: pointer;
    border-radius: 5px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.secteur-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.2);
}

.secteur-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.secteur-card:hover img {
    transform: scale(1.05);
}

.secteur-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    padding: 20px;
    color: white;
}

.secteur-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.secteur-description {
    font-size: 0.9rem;
    line-height: 1.4;
}
