#background-container {
    position: fixed;
    inset: 0;
    left: 10vw;
    max-width: 80%;
    z-index: -1;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 1;
}

#background-container img {
    max-width: 100%;
    max-height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
}



#main-content {
    opacity: 1;
    transition: opacity 0.25s ease-out;
    background-color: white;
}

#main-content.fade-out {
    opacity: 0;
}

#main-content.fade-in {
    opacity: 1;
}

.page-content {
    width: 95%;
    max-width: 1800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.page-content h1 {
    margin-bottom: 3rem;
    text-align: center;
    color: var(--text-color);
}

.info-section {
    margin-bottom: 3rem;
    padding: 2rem;
    background-color: #fff;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    width: 100%;
}

.form-group select {
    background-color: transparent;

}

.info-section h2 {
    color: var(--text-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.info-section h3 {
    color: var(--text-color);
    margin: 1.5rem 0 1rem;
    font-size: 1.2rem;
}

/* Locations grid layout */
.locations-grid {
    display: grid;
    gap: 2rem;
    max-width: 1600px;
    margin: 0 auto;
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
}

.location-card {
    margin: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.location-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

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

.jour {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    background-color: #f8f8f8;
    border-radius: 6px;
}

.jour-label {
    font-weight: 500;
}

.heures {
    color: var(--text-color);
}

.adresse {
    margin-bottom: 0;
    line-height: 1.6;
}

.map-placeholder {
    width: 100%;
    height: 300px;
    background-color: #f0f0f0;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    margin-top: auto;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-info a,
.address-lines {
    color: var(--text-color);
    text-decoration: none;
    transition: all var(--transition-speed);
}

.contact-info a:hover,
.address-lines:hover {
    color: var(--primary-color-dark);
}

@media (max-width: 768px) {
    .jour {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .map-placeholder {
        height: 250px;
    }
}

/* Team member styles */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

.team-member {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.member-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin-bottom: 1rem;
    background-color: #f0f0f0;
    background-size: 100%;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
    position: relative;
}

/* Show placeholder text only for member photos with placeholder class */
.member-photo.placeholder::after {
    content: 'Image à venir';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #666;
    font-size: 0.9rem;
    text-align: center;
    width: 100%;
    padding: 0 1rem;
}

/* Remove other placeholder styles */
.member-photo::before,
.member-photo::after,
.member-photo.placeholder::before {
    content: none;
}

.member-info h3 {
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.member-role {
    color: #666;
    font-style: italic;
}

.member-description {
    margin-top: 1rem;
    line-height: 1.6;
}

/* History page styles */
.history-entry {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.history-image {
    flex: 0 0 300px;
    height: 200px;
    background-color: #f0f0f0;
    border-radius: var(--border-radius);
}

.history-content {
    flex: 1;
}

.history-timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline-entry {
    position: relative;
    margin-bottom: 2rem;
    padding-left: 2rem;
}

.timeline-entry::before {
    content: '';
    position: absolute;
    left: -5px;
    top: 0;
    width: 12px;
    height: 12px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

.timeline-entry::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: -2rem;
    width: 2px;
    background-color: #ddd;
}

.timeline-entry:last-child::after {
    display: none;
}

.year {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* Contact form styles */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    height: 2.8rem;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    background-color: transparent;
    color: var(--text-color);
}

.form-group textarea {
    resize: vertical;
    height: 8rem;
}

.submit-button {
    background-color: var(--primary-color);
    color: var(--text-color);
    border: none;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    font-weight: 500;
    cursor: pointer;
    transition: background-color var(--transition-speed);
}

.submit-button:hover {
    background-color: var(--primary-color-dark);
}

/* Links page styles */
.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

.partner-card {
    display: block;
    text-decoration: none;
    color: var(--text-color);
    padding: 1rem;
    background-color: #f8f8f8;
    border-radius: var(--border-radius);
    border: 2px solid transparent;
    transition: all var(--transition-speed);
    position: relative;
}

.partner-card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.partner-info .contact-button {
    position: relative;
    z-index: 2;
}

.vehicle-features {
    position: relative;
    z-index: 2;
}

.partner-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.partner-logo {
    width: 100%;
    height: 150px;
    background-color: #f0f0f0;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
}

.partner-info h3 {
    margin-bottom: 0.5rem;
}

.links-list {
    list-style: none;
    padding: 0;
}

.links-list li {
    margin-bottom: 1rem;
}

.links-list a {
    color: var(--text-color);
    text-decoration: none;
    display: inline-block;
    padding: 0.5rem 0;
    transition: color var(--transition-speed);
}

.links-list a:hover {
    color: var(--primary-color-dark);
}

/* Placeholder styles */
.placeholder {
    background-color: #f0f0f0;
    position: relative;
}

.placeholder::after {
    content: 'Image à venir';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #666;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .history-entry {
        flex-direction: column;
    }

    .history-image {
        width: 100%;
        flex: none;
    }

    .jour {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

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

@media (max-width: 480px) {
    .info-section {
        padding: 1rem;
    }

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

    .member-photo {
        width: 150px;
        height: 150px;
    }
}

/* Contact button styles */
.contact-button-container {
    display: flex;
    justify-content: left;
    margin-top: 1.5rem;
}

.contact-button {
    display: inline-block;
    width: fit-content;
    padding: 0.75rem 2rem;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: background-color var(--transition-speed), transform var(--transition-speed);
}

.form-button {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    border: none;
    font-weight: 500;
    transition: background-color var(--transition-speed), transform var(--transition-speed);
}

.form-button:hover {
    cursor: pointer;
}

.contact-button:hover {
    background-color: var(--primary-color-dark);
    transform: translateY(-5px);
}

/* Icon styles */
.adresse p i,
.contact-info p i {
    width: 20px;
    margin-right: 8px;
    color: var(--primary-color);
}

.address-line {
    padding-left: 28px;
    /* 20px icon width + 8px margin */
}

/* Address block styles */
.address-block {
    display: flex;
    align-items: center;
    gap: 12px;
}

.address-block i {
    color: var(--primary-color);
    font-size: 1.2em;
    flex-shrink: 0;
}

.address-lines {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.address-lines p {
    margin: 0;
}

/* Timeline styles */
.timeline {
    position: relative;
    max-width: 1600px;
    margin: 4rem auto;
    padding: 2rem 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline::before {
    content: '';
    position: absolute;
    left: calc(50% - 350px);
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--primary-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    width: 100%;
    max-width: 700px;
    padding-left: 50px;
}

.timeline-dot {
    position: absolute;
    left: 1px;
    top: 30px;
    width: 20px;
    height: 20px;
    background-color: var(--primary-color);
    border-radius: 50%;
    transform: translateX(-50%);
    transition: all var(--transition-speed);
    z-index: 2;
}

.timeline-item:hover .timeline-dot,
.timeline-item.active .timeline-dot {
    background-color: var(--primary-color-dark);
    transform: translateX(-50%) scale(1.2);
}

.timeline-content {
    position: relative;
    width: 100%;
    max-width: 800px;
    padding: 1.5rem;
    background-color: white;
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all var(--transition-speed);
    opacity: 0.5;
    transform: translateX(0);
    display: flex;
    gap: 2rem;
    margin-left: 10px;
}

.timeline-text {
    flex: 1;
    min-width: 0;
}

.timeline-image {
    flex: 0 0 250px;
    margin: 0;
}

.timeline-item:hover .timeline-content,
.timeline-item.active .timeline-content {
    opacity: 1;
    transform: translateX(10px);
    border-color: var(--primary-color);
}

.timeline-content h3 {
    color: var(--primary-color);
    margin-bottom: 0.8rem;
    font-size: 1.4rem;
    line-height: 1.2;
}

.timeline-content p {
    margin-bottom: 1rem;
    line-height: 1.5;
    font-size: 1rem;
}

.timeline-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--border-radius);
}

/* Timeline responsive adjustments */
@media (max-width: 1024px) {
    .timeline {
        padding: 2rem 0 2rem 40px;
        margin: 2rem auto;
        display: block;
    }

    .timeline::before {
        left: 40px;
    }

    .timeline-item {
        padding-left: 40px;
        max-width: none;
    }

    .timeline-content {
        max-width: calc(100% - 40px);
    }
}

/* Timeline mobile styles */
@media (max-width: 768px) {
    .timeline {
        padding-left: 25px;
        margin: 1.5rem 0;
    }

    .timeline::before {
        left: 25px;
    }

    .timeline-item {
        transform: scale(1);
        transition: transform 0.3s ease;
    }

    .timeline-content {
        opacity: 0.7;
        border: 1px solid transparent;
        transition: all 0.3s ease;
    }

    .timeline-dot {
        transition: background-color 0.3s ease;
    }



    .timeline-item.hover-effect .timeline-content {
        opacity: 1;
        border-color: var(--primary-color);
        transform: scale(1.02);
    }

    .timeline-item.hover-effect .timeline-dot {
        background-color: var(--primary-color-dark);
    }

    .timeline-item {
        padding-left: 25px;
        margin-bottom: 2rem;
    }

    .timeline-dot {
        width: 16px;
        height: 16px;
        top: 20px;
        left: 10px;
    }

    .timeline-content {
        flex-direction: column;
        padding: 1rem;
        margin-left: 5px;
        max-width: calc(100% - 30px);
    }

    .timeline-text {
        order: 1;
        margin-bottom: 1rem;
    }

    .timeline-image {
        order: 2;
        width: 100%;
        flex: none;
        height: 200px;
        margin-bottom: 0;
    }

    .timeline-content h3 {
        font-size: 1.2rem;
        margin-bottom: 0.6rem;
    }

    .timeline-content p {
        font-size: 0.95rem;
        margin-bottom: 0.8rem;
    }
}

@media (max-width: 480px) {
    .timeline {
        padding-left: 20px;
        margin: 1rem 0;
        margin-bottom: 6rem;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item {
        padding-left: 20px;
        margin-bottom: 1.5rem;
    }

    .timeline-dot {
        width: 12px;
        height: 12px;
        top: 18px;
        left: 8px;
    }

    .timeline-content {
        padding: 0.8rem;
        margin-left: 2px;
        max-width: calc(100% - 22px);
    }

    .timeline-image {
        height: 160px;
    }

    .timeline-content h3 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }

    .timeline-content p {
        font-size: 0.9rem;
        line-height: 1.4;
        margin-bottom: 0.8rem;
    }

}

/* Lightbox styles */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    z-index: 5;
    display: none;
    justify-content: center;
    align-items: center;
    transition: background-color 0.2s ease-in-out;
}

.lightbox.active {
    background-color: rgba(0, 0, 0, 0.9);
}

.lightbox-content {
    position: relative;
    width: 95vw;
    height: 95vh;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.2s ease-in-out;
    display: flex;
    justify-content: center;
}

.lightbox.active .lightbox-content {
    opacity: 1;
    transform: scale(1);
}

.lightbox-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: var(--border-radius);
}

.lightbox-caption {
    position: absolute;
    bottom: -40px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-style: italic;
    padding: 10px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    transition: background-color var(--transition-speed);
}

.lightbox-close:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* Improved responsive design */
@media (max-width: 1024px) {
    .page-content {
        width: 95%;
    }

    .info-section {
        padding: 1.5rem;
    }

    .locations-grid {
        grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
        gap: 1.5rem;
    }

    .team-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .page-content {
        width: 100%;
        margin: 1rem auto;
        padding: 0 0.75rem;
    }

    .page-content h1 {
        margin-bottom: 2rem;
        font-size: clamp(1.5rem, 5vw, 2rem);
    }

    .info-section {
        margin-bottom: 2rem;
        padding: 1.25rem;
    }

    .info-section h2 {
        font-size: 1.3rem;
        margin-bottom: 1.25rem;
    }

    .history-entry {
        flex-direction: column;
        gap: 1rem;
    }

    .history-image {
        flex: none;
        width: 100%;
        max-height: 250px;
    }

    .jour {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .map-placeholder {
        height: 250px;
    }

    .timeline {
        padding: 1rem;
    }

    .timeline-content {
        padding: 1rem;
    }

    .timeline-image {
        height: 200px;
    }

    .contact-form {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .info-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .info-section h2 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
    }

    .info-section h3 {
        font-size: 1.1rem;
    }

    .team-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .member-photo {
        width: 150px;
        height: 150px;
    }

    .timeline {
        padding: 0.75rem;
    }

    .timeline-content {
        padding: 0.75rem;
    }

    .timeline-image {
        height: 180px;
    }

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

    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 0.5rem;
    }
}

/* Add fluid typography for better readability */
.page-content p,
.timeline-text,
.member-description,
.contact-info {
    font-size: clamp(0.9rem, 2vw, 1rem);
}

/* Activities and Services styles */

.activities-page .info-section {
    background: white;
    border-radius: 8px;
    border: 2px solid transparent;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: all 0.5s ease;
    height: fit-content;
    align-self: flex-start;
}

.activities-page .info-section:hover {
    transform: translateY(-5px);
    border: 2px solid var(--primary-color);
}

.activities-page .card-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 1.5rem;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s ease;
    position: relative;
}

.activities-page .card-header h2 {
    margin: 0;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-grow: 1;
}

.activities-page .card-header h2 i {
    color: var(--primary-color);
}

.activities-page .card-header .fa-chevron-down {
    color: var(--primary-color);
    position: absolute;
    right: 1.5rem;
    transition: transform 0.3s ease;
}

.activities-page .card-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    padding: 0 1.5rem;
}

.activities-page .info-section.expanded .card-content {
    max-height: 1000px;
    padding: 1.5rem;
}

.activities-page .info-section.expanded .fa-chevron-down {
    transform: rotate(180deg);
}

.activities-page .service-description {
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.activities-page .service-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.activities-page .service-list li:last-child {
    border-bottom: none;
}

.fa-check {
    color: var(--primary-color);
    font-size: 0.9em;
}


@media (max-width: 768px) {
    .activities-page .locations-grid {
        grid-template-columns: 1fr;
    }
}

/* Liens page styles */

.partners-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(250px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

.partner-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all var(--transition-speed);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.partner-card:hover {
    transform: translateY(-5px);
}

.partner-card-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.partner-logo {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.partner-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.partner-info h3 {
    margin-bottom: 1rem;
    color: var(--text-color);
    font-size: 1.3rem;
}

.partner-info p {
    margin-bottom: 1.5rem;
    line-height: 1.5;
    flex-grow: 1;
}

.contact-button-container {
    margin-top: auto;
    position: relative;
    z-index: 2;
}

.contact-button {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: var(--primary-color);
    color: var(--text-color);
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: all var(--transition-speed);
}

.contact-button:hover {
    background-color: var(--primary-color-dark);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .partners-grid {
        grid-template-columns: 1fr;
    }

    .partner-logo {
        height: 180px;
    }

    .partner-info {
        padding: 1.25rem;
    }
}

@media (max-width: 480px) {
    .partner-logo {
        height: 160px;
    }

    .partner-info {
        padding: 1rem;
    }

    .partner-info h3 {
        font-size: 1.2rem;
        margin-bottom: 0.75rem;
    }

    .partner-info p {
        margin-bottom: 1.25rem;
    }

    .contact-button {
        padding: 0.6rem 1.5rem;
    }
}