/* main.css */
:root {
    --primary: #0ca69b;
    --primary-dark: #097d75;
    --primary-light: #e6f6f5;
    --dark: #0b1120;
    --dark-secondary: #1e293b;
    --text-main: #334155;
    --text-muted: #64748b;
    --white: #ffffff;
    --bg-main: #f8fafc;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-lg: 1rem;
    --font-ar: 'Cairo', sans-serif;
    --font-en: 'Inter', sans-serif;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

html,
body {
    overflow-x: hidden;
}

body {
    font-family: var(--font-ar);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--dark);
    line-height: 1.3;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

/* Glassmorphism Classes */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.4s ease;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-sm);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    display: flex;
    flex-direction: column;
}

.brand-ar {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--primary-dark);
    margin: 0;
    line-height: 1;
}

.brand-en {
    font-family: var(--font-en);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-top: 0.2rem;
}

.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links li a {
    font-weight: 600;
    color: var(--text-main);
    position: relative;
}

.nav-links li a:not(.btn-primary)::after {
    content: '';
    position: absolute;
    bottom: -4px;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-links li a:hover:not(.btn-primary)::after {
    width: 100%;
}

.nav-links li a:hover:not(.btn-primary) {
    color: var(--primary);
}

/* Buttons */
.btn-primary {
    background: var(--primary);
    color: var(--white) !important;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    font-weight: 700;
    display: inline-block;
    box-shadow: 0 4px 14px 0 rgba(12, 166, 155, 0.39);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(12, 166, 155, 0.23);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    font-weight: 700;
    display: inline-block;
    backdrop-filter: blur(5px);
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--dark) !important;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transform: scale(1.05);
    transition: transform 10s ease-out;
    z-index: 1;
}

.hero:hover .hero-bg {
    transform: scale(1.1);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(11, 17, 32, 0.8) 0%, rgba(9, 125, 117, 0.5) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
    padding: 2rem;
}

.sub-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #ffd166;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.main-title {
    font-size: 4.5rem;
    font-weight: 900;
    color: var(--white);
    margin-bottom: 1.5rem;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.description {
    font-size: 1.5rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

/* About Section */
.about-section {
    padding: 8rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--dark);
    position: relative;
    display: inline-block;
}

.about-text h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: 0;
    width: 60px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
}

.about-text p {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.feature-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
}

.about-image {
    position: relative;
    border-radius: 2rem;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

.about-image:hover img {
    transform: scale(1.05);
}

.glass-float {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.glass-float h4 {
    color: var(--primary-dark);
    font-size: 1.25rem;
    font-weight: 800;
}

.glass-float p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* Gallery Section */
.gallery-section {
    padding: 6rem 2rem;
    background: var(--dark);
    color: var(--white);
}

.gallery-header {
    text-align: center;
    margin-bottom: 4rem;
}

.gallery-header h2 {
    font-size: 2.5rem;
    color: var(--white);
    margin-bottom: 1rem;
}

.gallery-header p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.2rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

.gallery-item {
    border-radius: calc(var(--radius-lg) - 0.5rem);
    overflow: hidden;
    position: relative;
    aspect-ratio: 4/3;
    cursor: pointer;
}

.gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover::after {
    opacity: 1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

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

/* Footer Section */
.footer {
    position: relative;
    background-image: url('images/DSC00199.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.footer-glass {
    background: rgba(11, 17, 32, 0.9);
    backdrop-filter: blur(10px);
    padding: 6rem 2rem 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 4rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 4rem;
    margin-bottom: 2rem;
}

.footer-brand h2 {
    color: var(--white);
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
    font-family: var(--font-en);
}

.footer-brand p:last-child {
    font-family: var(--font-ar);
    margin-top: 1rem;
    color: var(--primary-light);
}

.footer-contact h3 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

.contact-item .icon {
    font-size: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.contact-item p {
    font-size: 1.1rem;
}

.footer-bottom {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* Animations using Intersection Observer */
.hidden {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.hidden-left {
    opacity: 0;
    transform: translateX(50px);
    /* reversed for RTL */
    transition: all 0.8s ease-out;
}

.hidden-right {
    opacity: 0;
    transform: translateX(-50px);
    /* reversed for RTL */
    transition: all 0.8s ease-out;
}

.hidden-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.6s ease-out;
}

.show {
    opacity: 1 !important;
    transform: translate(0) scale(1) !important;
}

/* Initial Load Animation */
.fade-in-up {
    animation: fadeInUp 1s ease-out forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: var(--primary-dark);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Responsive */
@media (max-width: 900px) {
    .about-container {
        grid-template-columns: 1fr;
    }

    .about-image {
        order: -1;
    }

    .main-title {
        font-size: 3rem;
    }

    .hamburger {
        display: flex;
    }

    .nav-links {
        display: flex;
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: right 0.4s ease;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        margin: 0;
        padding: 0;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        margin: 1.5rem 0;
    }

    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }

    .contact-item {
        justify-content: center;
    }

    .glass-float {
        right: 10px;
        bottom: 10px;
        padding: 1rem;
    }
}

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

    .main-title {
        font-size: 2.5rem;
    }

    .description {
        font-size: 1.2rem;
    }

    .hero-actions {
        flex-direction: column;
    }
}