/* Moon Axis - Custom Styles */
/* Updated with Official Brand Colors from Visual Identity */

/* CSS Variables - Official Brand Colors */
:root {
    --brand-navy: #0C1F3A;
    /* Dark Navy Blue - Primary */
    --brand-teal: #86B9B1;
    /* Teal/Sea Green - Accent */
    --brand-white: #FAFDFC;
    /* Off-White - Light */
    --dark-primary: #0C1F3A;
    --dark-secondary: #0A1628;
    --dark-accent: #122A4D;
    --accent-blue: #86B9B1;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Tajawal', 'Hacen Tunisia', sans-serif;
    background-color: var(--brand-navy);
    color: var(--brand-white);
    overflow-x: hidden;
}

/* English text styling */
.font-english {
    font-family: 'Exo', sans-serif;
}

/* Navigation Glass Effect */
.nav-glass {
    background: rgba(12, 31, 58, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(134, 185, 177, 0.15);
}

.nav-scrolled {
    background: rgba(12, 31, 58, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Glass Card Effect */
.glass-card {
    background: rgba(10, 22, 40, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(134, 185, 177, 0.15);
    transition: all 0.3s ease;
}

.glass-card:hover {
    background: rgba(18, 42, 77, 0.8);
    border-color: rgba(134, 185, 177, 0.35);
}

/* Floating Animation */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

/* Particles Effect with Brand Colors */
.particles {
    background-image:
        radial-gradient(2px 2px at 20px 30px, rgba(134, 185, 177, 0.3), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(250, 253, 252, 0.2), transparent),
        radial-gradient(2px 2px at 50px 160px, rgba(134, 185, 177, 0.4), transparent),
        radial-gradient(2px 2px at 100px 20px, rgba(250, 253, 252, 0.3), transparent),
        radial-gradient(2px 2px at 120px 90px, rgba(134, 185, 177, 0.2), transparent),
        radial-gradient(2px 2px at 180px 200px, rgba(250, 253, 252, 0.4), transparent);
    background-size: 200px 200px;
    animation: particleMove 20s linear infinite;
}

@keyframes particleMove {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 200px 200px;
    }
}

/* Service Card Hover Effect */
.service-card {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px -12px rgba(134, 185, 177, 0.25);
}

/* Gallery Item Effect */
.gallery-item {
    position: relative;
    cursor: pointer;
}

.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(12, 31, 58, 0.8) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.gallery-item:hover::before {
    opacity: 1;
}

.gallery-item>div {
    z-index: 2;
}

/* Button Shine Effect */
.btn-shine {
    position: relative;
    overflow: hidden;
}

.btn-shine::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.3),
            transparent);
    transition: left 0.5s ease;
}

.btn-shine:hover::before {
    left: 100%;
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    right: 0;
    width: 3px;
    height: 0%;
    background: linear-gradient(180deg, var(--brand-teal), var(--brand-white));
    z-index: 9999;
    transition: height 0.1s ease;
}

/* Mobile Menu Animation */
#mobile-menu {
    transform-origin: top;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: scaleY(0);
    }

    to {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* Section Reveal Animation */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Custom Scrollbar with Brand Colors */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--brand-navy);
}

::-webkit-scrollbar-thumb {
    background: var(--brand-teal);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--brand-white);
}

/* Loading State */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--brand-navy);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid transparent;
    border-top-color: var(--brand-teal);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Gradient Text using Brand Colors */
.gradient-text {
    background: linear-gradient(135deg, var(--brand-teal), var(--brand-white));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .nav-link {
        font-size: 1.1rem;
    }

    h1 {
        font-size: 2.5rem !important;
    }

    h2 {
        font-size: 2rem !important;
    }

    .glass-card {
        padding: 1rem;
    }
}

/* RTL Specific Styles */
[dir="rtl"] .rotate-180 {
    transform: rotate(0deg);
}

/* Focus States for Accessibility */
a:focus,
button:focus {
    outline: 2px solid var(--brand-teal);
    outline-offset: 2px;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* Print Styles */
@media print {

    .nav-glass,
    #mobile-menu-btn,
    .gallery-item::before {
        display: none;
    }

    body {
        background: white;
        color: black;
    }
}