@import url('https://fonts.googleapis.com/css2?family=Pacifico&family=Amiri&display=swap');

/* Styles généraux */
body {
    font-family: 'Amiri', serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    text-align: right;
    direction: rtl;
}

header {
    display: flex;
    justify-content: space-between; /* Espace entre le logo et le menu */
    align-items: center;
    padding: 1.1rem;
    background: none;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 100%;
}

.logo-container {
    order: 1; /* Positionne le logo à gauche */
}

.nav-container {
    display: flex;
    align-items: center;
    order: 2; /* Positionne le menu à droite */
    margin-right: auto; /* Espace entre le logo et le menu */
}

header h1 {
    font-family: 'Amiri', serif;
    font-size: 3em; /* taille le logo */
    color: #E88812;
    text-shadow: 1px 1px #06B057;
    margin: 0;
    display: flex;
    align-items: center;
    cursor: pointer;
}

header img {
    margin-left: 10px; /* Séparation entre le logo et le texte */
    width: 3em;
    height: auto;
}

.language-selector {
    position: relative;
    cursor: pointer;
    margin-left: 2rem; /* Espace entre les éléments du menu */
}

.language-menu {
    display: none;
    position: absolute;
    right: 0; /* Assurez-vous que le menu de traduction s'ouvre à droite */
    top: 100%;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 1;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.language-menu a {
    display: block;
    padding: 10px;
    color: #333;
    text-decoration: none;
}

.language-menu a:hover {
    background-color: #f1f1f1;
}

.main-dropdown {
    position: relative;
    display: inline-block;
    margin-right: 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.6);
}

.main-dropbtn {
    background-color: #06B057;
    color: white;
    padding: 10px;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.main-dropbtn:hover {
    background-color: #E88812;
    transform: translateY(-2px);
}

.main-dropdown-content {
    display: none;
    position: absolute;
    left: 0; /* Assurez-vous que le menu principal s'ouvre à droite */
    top: 100%;
    background-color: #ffffff;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.main-dropdown-content a {
    color: #014583;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    background-color: #ffffff;
    position: relative;
    transition: color 0.3s ease;
}

.main-dropdown-content a:hover {
    background-color: #f1f1f1;
    color: #E88812;
    transform: translateX(5px);
}

.main-dropdown:hover .main-dropdown-content {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.main-dropdown-content span { 
    color: #014583; 
    padding: 12px 16px; 
    display: block; 
    font-size: 16px; 
    cursor: pointer; 
    background-color: #ffffff; 
    transition: background-color 0.3s ease, transform 0.3s ease; 
    width: 300px;
} 

.main-dropdown-content span:hover { 
    background-color: #f1f1f1; 
    color: #E88812; 
    transform: translateX(5px);
}

/* Styles des sous-menus */
.sub-dropdown-content {
    display: none;
    position: absolute;
    right: 0; /* Assurez-vous que les sous-menus s'ouvrent à droite */
    background-color: #ffffff;
    min-width: 300px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.plus-icon {
    margin-left: auto;
    padding-left: 10px;
    font-size: 0.8em;
    color: #06B057;
    transition: transform 0.3s ease, color 0.3s ease;
}

.sub-dropdown a:hover .plus-icon {
    color: #E88812;
    transform: rotate(45deg) scale(1.2);
}

body.dark-mode .sub-dropdown-content,
body.dark-mode .language-menu {
    background-color: #2a2a2a;
    color: #f4f4f4;
    border-color: #444444;
}

body.dark-mode .main-dropdown-content a,
body.dark-mode .sub-dropdown-content a,
body.dark-mode .language-menu a {
    color: #f4f4f4;
}

body.dark-mode .main-dropdown-content a:hover,
body.dark-mode .sub-dropdown-content a:hover,
body.dark-mode .language-menu a:hover {
    background-color: #444444;
}

body.dark-mode .dark-mode-toggle .dark-mode-label {
    color: #f4f4f4;
}

#dark-mode-icon {
    color: #014583; /* Couleur foncée pour le mode clair */
}

body.dark-mode #dark-mode-icon {
    color: #f4f4f4; /* Couleur claire pour le mode sombre */
}

/* Mobile */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav-container {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        width: 80%;
    }

.main-dropdown-content a {
        
    display: block;
    
    position: relative;
    
}
.main-dropdown-content {
    display: none;
    position: relative;
    right: 0; /* Assurez-vous que le menu principal s'ouvre à droite */
    top: 100%;
    background-color: #ffffff;
    min-width: 320px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

    .main-dropdown.open .main-dropdown-content {
        display: block;
    }

    .main-dropdown-content a {
        padding: 10px;
        
    }

.sub-dropdown-content {
    display: none;
    position: absolute;
    right: 0; /* Assurez-vous que les sous-menus s'ouvrent à droite */
    background-color: #ffffff;
    min-width: 300px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

    .sub-dropdown.open {
        display: block;
    }

    .language-selector {
        margin-top: 10px;
    }

    .search-container {
        margin-top: 10px;
        width: 100%;
        justify-content: flex-start;
    }

    #search-bar {
        width: 100%;
        max-width: none;
        margin-right: 10px;
    }

    .search-container button {
        position: relative;
        right: 0;
        margin-top: 10px;
    }

    .section {
        padding: 1rem;
        width: 100%;
        
    }

    .cta-button {
        width: 100%;
    }
}

.section {
    opacity: 0; 
    transform: translateY(50px); 
    transition: opacity 1s ease, transform 1s ease; 
}

.section.visible {
    opacity: 1; 
    transform: translateY(0); 
}

.search-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 20px 0;
    position: relative;
}

#search-bar {
    padding: 12px 20px;
    font-size: 16px;
    border: 2px solid #06B057;
    border-radius: 25px;
    outline: none;
    width: 60%;
    max-width: 600px;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    background-color: #fff;
    padding-right: 90px;
}

#search-bar:focus {
    border-color: #E88812;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    width: 75%;
    background-color: #f9f9f9;
}

.search-container button {
    position: absolute;
    right: 10px;
    background-color: transparent;
    border: none;
    cursor: pointer;
    color: #06B057;
    font-size: 20px;
    transition: color 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
}

.search-container button:hover {
    color: #E88812;
    transform: scale(1.1);
}

.search-container button i {
    font-size: 24px;
}

.main-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    flex: 1;
}

.section-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1rem;
    flex: 1;
}

.section {
    flex: 1;
    margin: 2rem 0;
    padding: 2rem;
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    width: 100%;
    max-width: 1200px;
    text-align: center;
}

.section-title {
    font-size: 2.5em;
    color: #014583;
    margin-bottom: 1rem;
}

.cta-button {
    background-color: #06B057;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 1em;
    cursor: pointer;
    border-radius: 25px;
    transition: background-color 0.3s ease, transform 0.3s ease;
    text-align: center;
}

.cta-button:hover {
    background-color: #E88812;
    transform: translateY(-2px);
}

.feature-buttons {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.feature-button {
    background-color: #fff;
    color: #014583;
    border: 2px solid #06B057;
    padding: 1.5rem;
    width: 300px;
    text-align: center;
    font-size: 1.2em;
    cursor: pointer;
    border-radius: 8px;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
}

.feature-button:hover {
    background-color: #06B057;
    color: white;
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 2.5em;
    margin-bottom: 1rem;
}

.testimonials-carousel {
    display: flex;
    overflow: hidden;
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.testimonial-item {
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    width: 100%;
    flex-shrink: 0;
    margin: 0 1rem;
    text-align: center;
}

.testimonial-item p {
    font-size: 1.2em;
    color: #333;
    margin-bottom: 1rem;
}

.testimonial-item h4 {
    font-size: 1em;
    color: #06B057;
}

#contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

#contact-form input,
#contact-form textarea {
    padding: 1rem;
    border: 2px solid #06B057;
    border-radius: 8px;
    font-size: 1em;
}

#contact-form textarea {
    resize: vertical;
    height: 150px;
}

#contact-form button {
    background-color: #06B057;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 1em;
    cursor: pointer;
    border-radius: 25px;
    transition: background-color 0.3s ease, transform 0.3s ease;
    text-align: center;
    margin-top: 1rem;
}

#contact-form button:hover {
    background-color: #E88812;
    transform: translateY(-2px);
}

footer {
    background: #014583;
    color: #fff;
    text-align: center;
    padding: 0.5rem;
    width: 100%;
    position: relative;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    margin-top: 2rem;
}

.social-icons {
    margin-top: 1rem;
}

.social-icons a {
    color: #fff;
    margin: 0 10px;
    font-size: 1.5em;
    text-decoration: none;
}

.social-icons a:hover {
    color: #E88812;
}

.dark-mode-toggle {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 12px 16px;
}

.dark-mode-label {
    font-size: 1em;
    color: #014583;
    margin-right: 10px;
}

.dark-mode-bar {
    width: 40px;
    height: 20px;
    background-color: #014583;
    position: relative;
    border-radius: 10px;
    overflow: hidden;
}

.dark-mode-knob {
    width: 20px;
    height: 20px;
    background-color: #06B057;
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 50%;
    transition: transform 0.5s ease-in-out;
}

/* Styles pour le mode sombre */
body.dark-mode .dark-mode-knob {
    transform: translateX(20px);
    background-color: #E88812;
}

body.dark-mode {
    background-color: #1a1a1a;
    color: #f4f4f4;
    transition: background-color 0.5s ease-in-out, color 0.5s ease-in-out;
}

body.dark-mode header {
    background-color: #1e1e1e;
    color: #f4f4f4;
}

body.dark-mode .main-dropdown-content, 
body.dark-mode .sub-dropdown-content, 
body.dark-mode .language-menu {
    background-color: #2a2a2a;
    color: #f4f4f4;
    border-color: #444444;
}

body.dark-mode .main-dropdown-content a, 
body.dark-mode .sub-dropdown-content a, 
body.dark-mode .language-menu a {
    color: #f4f4f4;
}

body.dark-mode .main-dropdown-content a:hover, 
body.dark-mode .sub-dropdown-content a:hover, 
body.dark-mode .language-menu a:hover {
    background-color: #444444;
}

body.dark-mode .card-item {
    background-color: #2a2a2a;
    color: #f4f4f4;
    border-color: #444444;
}

body.dark-mode .nav-button {
    background-color: #444444;
    color: #f4f4f4;
}

body.dark-mode .nav-button:hover {
    background-color: #E88812;
    color: #f4f4f4;
}

body.dark-mode .dark-mode-toggle .dark-mode-label {
    color: #f4f4f4;
}

#dark-mode-icon {
    color: #014583; /* Couleur foncée pour le mode clair */
}

body.dark-mode #dark-mode-icon {
    color: #f4f4f4; /* Couleur claire pour le mode sombre */
}
