/* Custom CSS for Al Rayan Travel Agency */

/* Smooth scrolling for the entire page */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #2563eb, #10b981);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #1d4ed8, #059669);
}

/* Header scroll effect */
.header-scrolled {
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(20px) !important;
}

/* Hero section enhancements */
.hero-gradient {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.8), rgba(6, 78, 59, 0.8));
}

/* Service card hover effects */
.service-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover {
    transform: translateY(-8px) scale(1.02);
}

/* Destination card image overlay */
.destination-card img {
    transition: transform 0.5s ease;
}

.destination-card:hover img {
    transform: scale(1.1);
}

/* Button animations */
.btn-primary {
    position: relative;
    overflow: hidden;
}

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

.btn-primary:hover::before {
    left: 100%;
}

/* Form input focus effects */
.form-input:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Social media icon hover effects */
.social-icon {
    transition: all 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-3px) rotate(5deg);
}

/* Floating animation for scroll indicator */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.scroll-indicator {
    animation: float 2s ease-in-out infinite;
}

/* Gradient text effect */
.gradient-text {
    background: linear-gradient(135deg, #2563eb, #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Card shadow variations */
.card-shadow-light {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.card-shadow-medium {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.card-shadow-heavy {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Loading animation for buttons */
.btn-loading {
    position: relative;
    color: transparent;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid transparent;
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive image gallery */
.image-gallery {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

/* Responsive map container */
@media (max-width: 1024px) {
    .google-maps-container {
        height: 60vh;
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    .google-maps-container {
        height: 50vh;
        min-height: 250px;
    }
    
    .google-maps-container h3 {
        font-size: 1.5rem;
    }
}

/* Mobile menu slide animation */
.mobile-menu-slide {
    transform: translateY(0) !important;
}

/* Mobile menu positioning and styling */
#mobile-menu {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    right: 0 !important;
    background: white !important;
    z-index: 9999 !important;
    min-height: 350px !important;
    width: 100% !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
    border-radius: 0 0 8px 8px !important;
    border: 1px solid #e5e7eb !important;
}

#mobile-menu .px-4 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}

#mobile-menu .py-6 {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
}

#mobile-menu.mobile-menu-slide {
    transform: translateY(0) !important;
}

/* Debug: Make sure mobile menu is visible when open */
#mobile-menu.mobile-menu-slide {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

/* Debug: Hide mobile menu when closed */
#mobile-menu:not(.mobile-menu-slide) {
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Ensure mobile menu button is always visible on mobile */
@media (max-width: 768px) {
    #mobile-menu-btn {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    /* Debug styles for mobile menu button */
    #mobile-menu-btn {
        background: rgba(59, 130, 246, 0.1);
        border: 2px solid #3b82f6;
        border-radius: 8px;
        min-width: 44px;
        min-height: 44px;
    }
    
    #mobile-menu-btn:hover {
        background: rgba(59, 130, 246, 0.2);
        transform: scale(1.05);
    }
}

/* Parallax effect for hero background */
.parallax-bg {
    transform: translateZ(0);
    will-change: transform;
    transition: transform 0.1s ease-out;
}

/* Enhanced parallax with better overlay visibility */
.hero-gradient {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.8), rgba(6, 78, 59, 0.8));
    z-index: 10;
    position: relative;
}

/* Text reveal animation */
.text-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.text-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Animate on scroll classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered animation delays for service cards */
.service-card:nth-child(1) { transition-delay: 0.1s; }
.service-card:nth-child(2) { transition-delay: 0.2s; }
.service-card:nth-child(3) { transition-delay: 0.3s; }
.service-card:nth-child(4) { transition-delay: 0.4s; }
.service-card:nth-child(5) { transition-delay: 0.5s; }
.service-card:nth-child(6) { transition-delay: 0.6s; }

/* Staggered animation delays for destination cards */
.destination-card:nth-child(1) { transition-delay: 0.1s; }
.destination-card:nth-child(2) { transition-delay: 0.2s; }
.destination-card:nth-child(3) { transition-delay: 0.3s; }
.destination-card:nth-child(4) { transition-delay: 0.4s; }
.destination-card:nth-child(5) { transition-delay: 0.5s; }
.destination-card:nth-child(6) { transition-delay: 0.6s; }

/* Enhanced service card animations */
.service-card {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Enhanced destination card animations */
.destination-card {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.destination-card.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Custom focus styles for accessibility */
*:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .bg-gray-50 {
        background-color: #ffffff;
    }
    
    .text-gray-600 {
        color: #000000;
    }
    
    .border-gray-300 {
        border-color: #000000;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .scroll-indicator {
        animation: none;
    }
}

/* Print styles */
@media print {
    .header,
    .footer,
    button,
    .mobile-menu {
        display: none !important;
    }
    
    body {
        color: #000000;
        background: #ffffff;
    }
    
    .hero-section {
        min-height: auto;
        padding: 2rem 0;
    }
}

/* Custom utility classes */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.backdrop-blur-custom {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.glass-effect {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Enhanced button states */
.btn-primary:active {
    transform: scale(0.98);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Form validation styles */
.form-input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input.success {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

/* Loading skeleton animation */
@keyframes shimmer {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
}

/* Google Maps styling */
.google-maps-container {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.google-maps-container iframe {
    transition: transform 0.3s ease;
}

.google-maps-container:hover iframe {
    transform: scale(1.02);
}

.google-maps-container.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
    z-index: 1;
}

.google-maps-container.loading::after {
    content: 'Loading map...';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #6b7280;
    font-weight: 600;
    z-index: 2;
}

.google-maps-container.loaded {
    animation: mapFadeIn 0.5s ease-out;
}

.google-maps-container.clicked {
    transform: scale(0.98);
}

@keyframes mapFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Map link styling */
.map-link {
    transition: all 0.3s ease;
}

.map-link:hover {
    transform: translateY(-2px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Custom cursor for interactive elements */
.interactive {
    cursor: pointer;
}

.interactive:hover {
    cursor: pointer;
}

/* Enhanced focus ring for better accessibility */
.focus-ring:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.5);
}

/* Smooth transitions for all interactive elements */
* {
    transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
}
