@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;700&display=swap');

:root {
    --primary-color: #4fc1b8;
    --secondary-color: #6c4a1e;
    --background-color: #f9f9f9;
    --text-color: #333;
    --white: #fff;
}

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

body {
    font-family: 'Tajawal', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    direction: rtl;
    background-color: var(--background-color);
}

header {
    background-color: var(--white);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s ease;
    height: 63px;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 1.5rem;
}

nav ul li a {
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: bold;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: var(--primary-color);
}

.logo img {
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.1);
}

.contact-icons {
    display: flex;
    margin-left: 60px;
}

.contact-item {
    position: relative;
    margin-left: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-item i {
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.contact-item i:hover {
    color: var(--primary-color);
}

.contact-item span {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    background: var(--white);
    border: 1px solid var(--secondary-color);
    border-radius: 5px;
    padding: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    min-width: 200px; 
    text-align: center;
}

.contact-item:hover span {
    opacity: 1;
    visibility: visible;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.hero {
    position: relative;
    color: var(--white);
    text-align: center;
    padding: 8rem 2rem;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-background img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.hero-background img.active {
    opacity: 1;
}

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

.hero-content {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
}

.cta-button {
    background: var(--primary-color);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s ease;
}

.cta-button:hover {
    background: var(--secondary-color);
}

.about, .vision-mission, .services, .contact {
    padding: 4rem 2rem;
}

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

.about .content {
    max-width: 50%;
}

.about img {
    width: 40%;
    border-radius: 10px;
}

.vision-mission {
    display: flex;
    justify-content: space-around;
}

.vision, .mission {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    flex: 1;
    margin: 0 1rem;
}

.services {
    text-align: center;
}

.service-grid {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
}

.service {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    width: 30%;
    margin-bottom: 2rem;
}

.service img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.contact-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.contact-info, #contact-form {
    width: 48%;
}

.contact-info h3 {
    margin-bottom: 1rem;
}

.contact-info p {
    margin-bottom: 0.5rem;
}

.contact-info i {
    margin-right: 0.5rem;
    color: var(--primary-color);
}

#contact-form {
    display: flex;
    flex-direction: column;
}

#contact-form label {
    margin-bottom: 0.5rem;
}

#contact-form input, #contact-form textarea {
    padding: 0.5rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
}

#contact-form button {
    background: var(--primary-color);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s ease;
}

#contact-form button:hover {
    background: var(--secondary-color);
}

footer {
    background: var(--secondary-color);
    color: var(--white);
    text-align: center;
    padding: 1rem 0;
}

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.gallery {
    margin-bottom: 2rem;
}

.gallery h2 {
    text-align: center;
    margin-bottom: 1rem;
}

.gallery-container {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: tuch;
    scrollbar-width: none;  /* For Firefox */
    -ms-overflow-style: none;  /* For Internet Explorer and Edge */
}

.gallery-container::-webkit-scrollbar {
    display: none;  /* For Chrome, Safari, and Opera */
}

.gallery-item {
    flex: 0 0 auto;
    width: 300px;
    height: 200px;
    margin-right: 1rem;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 5px;
}

.gallery-prev,
.gallery-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 1rem;
    text-decoration: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.gallery-prev {
    left: 1rem;
}

.gallery-next {
    right: 1rem;
}

@media (max-width: 768px) {
    .about {
        flex-direction: column;
    }

    .about .content, .about img {
        max-width: 100%;
        width: 100%;
    }

    .service {
        width: 100%;
    }

    .contact-container {
        flex-direction: column;
    }

    .contact-info, #contact-form {
        width: 100%;
    }

    nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--white);
        padding: 1rem;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    nav ul.show {
        display: flex;
    }

    nav ul li {
        margin: 1rem 0;
    }

    .menu-toggle {
        display: block;
    }
}

#map {
    height: 500px;
    width: 100%;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-item img:hover {
    transform: scale(1.05);
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
}

.modal-content {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 800px;
    max-height: 80vh;
    object-fit: contain;
}

.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

.nav-btn {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white;
    font-weight: bold;
    font-size: 20px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
    background-color: rgba(0, 0, 0, 0.8);
}

.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev {
    left: 0;
}

.nav-btn:hover {
    background-color: rgba(0, 0, 0, 0.9);
}
.social-icons {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}

.social-icons a {
    color: #333;
    font-size: 20px;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: #007bff;
}