/* ===== SITE BASE STYLES - GENERAL AUTHORITY FOR SUPERVISION & INSPECTION ===== */

/* ===== PROFESSIONAL LOADING SPINNER ===== */
.loading-spinner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #002623 0%, #054239 25%, #428177 50%, #988561 75%, #b9a779 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease-out, visibility 0.8s ease-out;
}

.loading-spinner.hidden {
    opacity: 0;
    visibility: hidden;
}

.spinner-container {
    text-align: center;
    color: white;
    padding: 2rem;
    max-width: 400px;
    margin: 0 auto;
}

.spinner {
    width: 120px;
    height: 120px;
    border: 6px solid rgba(255, 255, 255, 0.3);
    border-top: 6px solid #ffffff;
    border-radius: 50%;
    animation: spin 1.2s linear infinite;
    margin: 0 auto 25px;
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
}

.spinner-logo {
    width: 180px;
    height: 180px;
    margin-bottom: 20px;
    animation: pulse 2s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.3));
}

.loading-text {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 15px;
    opacity: 0.95;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.loading-dots {
    display: inline-block;
    animation: dots 1.5s infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

@keyframes dots {

    0%,
    20% {
        content: '.';
    }

    40% {
        content: '..';
    }

    60% {
        content: '...';
    }

    80%,
    100% {
        content: '';
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ===== BASE STYLES ===== */
body {
    font-family: 'Tajawal', sans-serif;
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
    transform: translateZ(0);
}

/* ===== NAVBAR STYLES ===== */
.navbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
    width: 100% !important;
    background: linear-gradient(135deg, #002623 0%, #054239 25%, #428177 50%, #988561 75%, #b9a779 100%) !important;
    border-bottom: 3px solid #b9a779 !important;
    box-shadow: 0 4px 20px rgba(185, 167, 121, 0.4) !important;
    min-height: 80px !important;
    transform: translateZ(0) !important;
    will-change: transform, background, padding, box-shadow, min-height !important;
    backface-visibility: hidden !important;
    perspective: 1000px !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
}

.navbar.navbar-compact {
    background: rgba(0, 38, 35, 0.92) !important;
    backdrop-filter: blur(25px) !important;
    -webkit-backdrop-filter: blur(25px) !important;
    padding: 1rem 0 !important;
    min-height: 60px !important;
    border-bottom: 2px solid #b9a779 !important;
    box-shadow: 0 2px 15px rgba(185, 167, 121, 0.3) !important;
}

.navbar-brand {
    display: flex !important;
    align-items: center !important;
    gap: 1rem !important;
    transition: all 0.4s ease !important;
}

.navbar-brand img {
    height: 60px !important;
    transition: all 0.4s ease !important;
}

.navbar.navbar-compact .navbar-brand img {
    height: 40px !important;
}

.navbar-brand span {
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    color: white !important;
    transition: all 0.4s ease !important;
}

.navbar.navbar-compact .navbar-brand span {
    font-size: 1rem !important;
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500 !important;
    padding: 0.75rem 1rem !important;
    margin: 0 0.25rem !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    position: relative !important;
    overflow: hidden !important;
}

.navbar-nav .nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.navbar-nav .nav-link:hover::before {
    left: 100%;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.1) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2) !important;
}

.navbar-nav .nav-link i {
    margin-right: 0.5rem !important;
    transition: transform 0.3s ease !important;
}

.navbar-nav .nav-link:hover i {
    transform: scale(1.1) !important;
}

/* ===== LANGUAGE SWITCHER ===== */
.language-switcher .btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.5) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500 !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    background: transparent !important;
    padding: 0.5rem 1rem !important;
    position: relative !important;
    z-index: 1002 !important;
}

.language-switcher .btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.8) !important;
    color: #fff !important;
    transform: translateY(-1px) !important;
}

.language-switcher .dropdown-menu {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(15px) !important;
    border: 1px solid rgba(185, 167, 121, 0.2) !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1) !important;
    padding: 0.5rem 0 !important;
    margin-top: 0.5rem !important;
}

.dropdown-menu .dropdown-item {
    color: #333 !important;
    background: transparent !important;
    border: none !important;
    padding: 0.5rem 1rem !important;
    transition: all 0.2s ease !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.5rem !important;
}

.dropdown-menu .dropdown-item:hover {
    background: rgba(66, 129, 119, 0.1) !important;
    color: #428177 !important;
    transform: translateX(2px) !important;
}

.dropdown-menu .dropdown-item img {
    width: 20px !important;
    height: 15px !important;
    object-fit: cover !important;
    border-radius: 2px !important;
}

/* ===== MAIN CONTENT ===== */
main {
    min-height: calc(100vh - 200px);
    animation: fadeIn 0.8s ease-out;
}

/* ===== FOOTER STYLES ===== */
.footer {
    background: linear-gradient(135deg, #002623 0%, #054239 100%);
    color: white;
    padding: 3rem 0 2rem;
    margin-top: auto;
}

.footer h5 {
    color: #b9a779;
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
}

.footer h5::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 2px;
    background: #b9a779;
    border-radius: 1px;
}

.footer ul.list-unstyled li {
    margin-bottom: 0.75rem;
}

.footer ul.list-unstyled li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.footer ul.list-unstyled li a:hover {
    color: #b9a779;
    transform: translateX(5px);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-footer-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(185, 167, 121, 0.2);
    color: #b9a779;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(185, 167, 121, 0.3);
}

.social-footer-link:hover {
    background: #b9a779;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(185, 167, 121, 0.4);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .navbar-brand span {
        font-size: 0.9rem !important;
    }

    .navbar-brand img {
        height: 45px !important;
    }

    .navbar.navbar-compact .navbar-brand img {
        height: 35px !important;
    }

    .navbar-nav .nav-link {
        padding: 0.5rem 0.75rem !important;
        margin: 0.25rem 0 !important;
    }
}

/* ===== UTILITY CLASSES ===== */
.bg-gradient-primary {
    background: linear-gradient(135deg, #002623 0%, #054239 25%, #428177 50%, #988561 75%, #b9a779 100%) !important;
}

.text-primary-custom {
    color: #428177 !important;
}

.text-secondary-custom {
    color: #b9a779 !important;
}

/* ===== ANIMATIONS ===== */
.fade-in {
    animation: fadeIn 0.8s ease-out;
}

.slide-up {
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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