body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f9;
    color: #333;
    line-height: 1.6;
    transition: all 0.3s ease;
}

body[data-lang="ar"] {
    direction: ltr;
}

header {
    background-color: #507786;
    padding: 1em;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    color: white;
    margin: 0;
    font-size: 1.8em;
}

.hamburger {
    display: none;
    font-size: 1.5em;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0 10px;
}

nav ul {
    padding: 0;
    list-style-type: none;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 0;
}

nav ul li {
    margin: 5px 0;
}

nav ul li a {
    color: #e6e6e6;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 1.1em;
}

nav ul li a:hover {
    color: #fff;
}

main {
    padding: 1.5em;
    position: relative;
}

section {
    margin-bottom: 3em;
}

#home h2, #services h2, #about h2, #contact h2, #shop h2 {
    color: #507786;
    font-size: 1.8em;
    text-align: center;
    margin-bottom: 0.5em;
}

#shop p {
    text-align: center;
    margin-bottom: 2em;
    font-size: 1.1em;
}

.hero-img {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    margin-bottom: 1em;
    animation: fadeIn 2s;
    border-radius: 8px;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.about-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.about-text {
    text-align: justify;
}

.about-content ul {
    list-style-type: none;
    padding-left: 0;
}

.about-content li {
    margin-bottom: 10px;
}

.about-img {
    width: 100%;
    max-height: 250px;
    object-fit: cover;
    margin-bottom: 20px;
    animation: fadeIn 2s;
    border-radius: 4px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    animation: slideIn 1s ease-out;
}

.shop-categories {
    display: flex;
    flex-direction: column;
    gap: 2em;
    width: 100%;
}

.shop-category {
    background: #e6f3f8;
    border-radius: 8px;
    padding: 1.5em;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    width: 100%;
}

.shop-category:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.shop-category h3 {
    color: #507786;
    margin: 0.5em 0 1.5em 0;
    font-size: 1.4em;
    text-align: center;
}

.shop-items-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    animation: slideIn 1s ease-out;
    width: 100%;
    max-width: none;
}

@keyframes slideIn {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.shop-item {
    background: #ffffff;
    border-radius: 8px;
    padding: 1em;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 280px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.shop-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.shop-item-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.shop-item h4 {
    margin: 0.5em 0;
    color: #507786;
    font-size: 1em;
    line-height: 1.2;
}

.shop-item p {
    margin: 0.5em 0;
    font-size: 0.85em;
    color: #555;
    flex-grow: 1;
}

.service {
    background: #e6f3f8;
    border-radius: 8px;
    padding: 1.5em;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 300px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.service:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.service-img {
    width: 100%;
    max-width: 200px;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
    padding-top: 10px;
}

.service h3 {
    color: #507786;
    margin: 0.5em 0;
    font-size: 1.2em;
    text-align: center;
}

.buy-btn, .book-btn {
    background-color: #507786;
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s;
    font-size: 1em;
}

.buy-btn:hover, .book-btn:hover {
    background-color: #456672;
}

.contact-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

#contact form {
    display: flex;
    flex-direction: column;
    background: #e6f3f8;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

#contact input, #contact textarea {
    margin: 10px 0;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    transition: border-color 0.3s, transform 0.3s;
}

#contact input:focus, #contact textarea:focus {
    border-color: #507786;
    outline: none;
    transform: scale(1.03);
}

#contact button {
    background-color: #507786;
    color: white;
    padding: 10px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s, transform 0.3s;
}

#contact button:hover {
    background-color: #456672;
    transform: scale(1.05);
}

.contact-img {
    width: 100%;
    max-height: 250px;
    object-fit: cover;
    border-radius: 4px;
}

.form-status, .order-status {
    margin: 10px 0;
    text-align: center;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.5s;
    padding: 15px;
    border-radius: 5px;
}

.order-status.success {
    background-color: #e6f3f8;
    color: #507786;
    opacity: 1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.order-status.error {
    background-color: #f8e6e6;
    color: #860000;
    opacity: 1;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

#contact-form.shake {
    animation: shake 0.5s;
}

.form-status.success {
    color: green;
    opacity: 1;
}

.form-status.error {
    color: red;
    opacity: 1;
}

footer {
    background-color: #507786;
    padding: 1em;
    text-align: center;
    color: white;
}

.footer-logo {
    width: 50px;
    height: 50px;
    margin-top: 10px;
    border-radius: 50%;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border-radius: 5px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    animation: slideDown 0.5s;
}

@keyframes slideDown {
    from { transform: translateY(-100px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.close, .close-btn {
    color: #aaa;
    float: right;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover, .close-btn:hover {
    color: black;
}

.modal-content form {
    display: flex;
    flex-direction: column;
}

.modal-content input, .modal-content textarea {
    margin: 10px 0;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    transition: border-color 0.3s;
}

.modal-content input:focus, .modal-content textarea:focus {
    border-color: #507786;
    outline: none;
}

.modal-content button {
    background-color: #4CAF50;
    color: white;
    padding: 10px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
    width: 100%;
}

.modal-content button:hover {
    background-color: #45a049;
}

/* Responsive Design */
@media screen and (max-width: 1400px) {
    .shop-items-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media screen and (max-width: 1200px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .shop-items-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 900px) {
    .shop-items-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

@media screen and (max-width: 768px) {
    header {
        flex-wrap: wrap;
    }

    .hamburger {
        display: block;
    }

    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
        background-color: #507786;
        position: absolute;
        top: 100%;
        left: 0;
        padding: 10px 0;
    }

    nav ul.active {
        display: flex;
    }

    nav ul li {
        margin: 10px 0;
        text-align: center;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .shop-items-grid {
        grid-template-columns: 1fr;
    }

    .service-img, .shop-item-img {
        height: 140px;
    }

    .about-content, .contact-container {
        flex-direction: column;
    }

    .about-img, .contact-img {
        max-width: 100%;
        max-height: 200px;
    }

    .order-status {
        font-size: 0.9em;
        padding: 10px;
    }
}

@media screen and (max-width: 600px) {
    header, main, footer {
        padding: 1em;
    }

    header h1 {
        font-size: 1.5em;
        text-align: center;
    }

    .hero-img {
        max-height: 200px;
    }

    .service-img, .shop-item-img {
        height: 120px;
    }

    .buy-btn, .book-btn {
        padding: 8px 16px;
        font-size: 0.9em;
    }

    .modal-content {
        width: 95%;
        margin: 20% auto;
    }

    .order-status {
        font-size: 0.8em;
    }

    .shop-category {
        padding: 1em;
    }
}

@media screen and (min-width: 769px) {
    .about-content {
        flex-direction: row;
        justify-content: space-between;
    }

    .about-text {
        flex: 1;
        margin-left: 20px;
    }

    .about-img {
        flex: 1;
        max-width: 50%;
    }

    .contact-container {
        flex-direction: row;
    }

    .contact-img {
        max-width: 50%;
    }

    #contact form {
        flex: 1;
        margin-right: 20px;
    }
}