/* Custom CSS for Cairo Adventure Landing Page */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Arabic:wght@300;400;500;600;700&display=swap');

/* Font Family Classes */
.font-playfair {
    font-family: 'Playfair Display', serif;
}

.font-arabic {
    font-family: 'Noto Sans Arabic', Arial, sans-serif;
}

.font-inter {
    font-family: 'Inter', sans-serif;
}

/* Base Styles */
* {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
}

/* Hero Section Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content > * {
    animation: fadeInUp 0.8s ease-out forwards;
}

.hero-content > *:nth-child(2) {
    animation-delay: 0.2s;
}

.hero-content > *:nth-child(3) {
    animation-delay: 0.4s;
}

.hero-content > *:nth-child(4) {
    animation-delay: 0.6s;
}

/* Custom Gradient Backgrounds */
.bg-egypt-gradient {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #92400e 100%);
}

.bg-sand-pattern {
    background-image: 
        radial-gradient(circle at 2px 2px, rgba(245, 158, 11, 0.1) 1px, transparent 0);
    background-size: 20px 20px;
}

/* Custom Animations */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.float-animation {
    animation: float 3s ease-in-out infinite;
}

/* Hover Effects */
.hover-lift {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Image Gallery Styles */
.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    transition: transform 0.5s ease;
}

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

/* Egyptian-themed decorative elements */
.pyramid-decoration {
    position: relative;
}

.pyramid-decoration::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: linear-gradient(45deg, #f59e0b, #d97706);
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

/* Location Map Styles */
.map-container {
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border: 3px solid #f59e0b;
}

/* Pricing Card Enhancements */
.pricing-highlight {
    position: relative;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 50%, #f59e0b 100%);
    border: 2px solid #f59e0b;
}

.pricing-highlight::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #f59e0b, #d97706, #92400e);
    border-radius: inherit;
    z-index: -1;
    filter: blur(8px);
    opacity: 0.7;
}

/* Button Enhancements */
.btn-primary {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    border: none;
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.3);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(245, 158, 11, 0.4);
    background: linear-gradient(135deg, #d97706 0%, #92400e 100%);
}

/* Form Styling */
.contact-form input:focus {
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

/* Loading Animation */
.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #f59e0b;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

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

/* Responsive Enhancements */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
        line-height: 1.1;
    }
    
    .hero-subtitle {
        font-size: 1.25rem;
    }
    
    .pricing-amount {
        font-size: 3rem;
    }
    
    .section-padding {
        padding: 3rem 0;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .pricing-amount {
        font-size: 2.5rem;
    }
    
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus States */
button:focus,
a:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 3px solid #f59e0b;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}

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

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

::-webkit-scrollbar-thumb {
    background: #f59e0b;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #d97706;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .text-gray-600 {
        color: #000000 !important;
    }
    
    .bg-amber-600 {
        background-color: #000000 !important;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .auto-dark {
        background-color: #1f2937;
        color: #f9fafb;
    }
}

/* Smooth Scrolling Enhancement */
html {
    scroll-padding-top: 80px; /* Account for fixed nav */
}

/* Hero Section Background Enhancement */
.hero-section {
    position: relative;
    overflow: hidden;
}

.hero-bg {
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    filter: brightness(0.9) contrast(1.1) saturate(1.1);
    transition: transform 0.3s ease-out, filter 0.3s ease-out;
    animation: subtle-zoom 20s ease-in-out infinite;
}

/* Subtle zoom animation for hero background */
@keyframes subtle-zoom {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Hover effect for hero section */
.hero-section:hover .hero-bg {
    filter: brightness(1) contrast(1.2) saturate(1.2);
}

/* Enhanced overlay for better text readability over Nile River image */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        135deg, 
        rgba(245, 158, 11, 0.2) 0%, 
        rgba(217, 119, 6, 0.3) 35%, 
        rgba(146, 64, 14, 0.4) 100%
    );
    z-index: 5;
}

/* Hero content styling */
.hero-content {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    background: rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    padding: 1rem 2rem 2rem 2rem;
    margin-top: 3rem;
}

/* Enhance text readability */
.hero-content h1, .hero-content p {
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.7);
}

/* Logo Styling */
.logo-container {
    transition: transform 0.3s ease;
    position: relative;
    padding-top: 2rem;
}

.logo-container:hover {
    transform: scale(1.05);
}

.logo-container img {
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
}

/* Specific styling for hero logo */
.hero-logo {
    transform: translateY(10px);
    animation: float-gently 4s ease-in-out infinite;
}

/* Gentle floating animation for logo */
@keyframes float-gently {
    0%, 100% { 
        transform: translateY(10px);
    }
    50% { 
        transform: translateY(0px);
    }
}

.nav-logo {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

.nav-logo:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Arabic RTL Specific Styles */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .text-left {
    text-align: right;
}

[dir="rtl"] .text-right {
    text-align: left;
}

[dir="rtl"] .text-center {
    text-align: center;
}

/* RTL Button and Icon Adjustments */
[dir="rtl"] .fas {
    margin-left: 0.5rem;
    margin-right: 0;
}

[dir="rtl"] .flex-row-reverse {
    flex-direction: row-reverse;
}

/* RTL Navigation adjustments */
[dir="rtl"] .space-x-reverse > :not([hidden]) ~ :not([hidden]) {
    --tw-space-x-reverse: 1;
}

/* Arabic Typography */
.font-arabic {
    line-height: 1.8;
    letter-spacing: 0.02em;
}

.font-arabic h1,
.font-arabic h2,
.font-arabic h3,
.font-arabic h4,
.font-arabic h5,
.font-arabic h6 {
    font-weight: 600;
    line-height: 1.4;
}

/* RTL Form adjustments */
[dir="rtl"] input,
[dir="rtl"] textarea,
[dir="rtl"] select {
    text-align: right;
}

[dir="rtl"] input[type="date"] {
    text-align: left; /* Keep date fields left-to-right */
}

/* Phone numbers should always display LTR */
[dir="rtl"] a[href^="tel:"],
[dir="rtl"] a[href^="https://wa.me/"],
[dir="rtl"] .phone-number {
    direction: ltr;
    text-align: left;
    display: inline-block;
}

/* RTL Gallery overlay adjustments */
[dir="rtl"] .gallery-item .absolute.bottom-4 {
    right: 1rem;
    left: auto;
}

/* Smooth transitions for language switching */
* {
    transition: text-align 0.3s ease, direction 0.3s ease;
}

/* Prevent unwanted text movement for key elements */
h2.font-bold, .text-center h2 {
    transform: translateZ(0) !important;
    will-change: auto !important;
    position: relative !important;
}

/* Ensure stable positioning for hotel name */
[data-translate="hotel.name"] {
    position: relative !important;
    transform: translateZ(0) !important;
    backface-visibility: hidden !important;
    will-change: auto !important;
    font-display: block !important;
}

/* Additional stability for all text elements */
.text-center h2, .font-bold {
    transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Hero Background Animation */
.hero-bg {
    animation: slowZoom 30s ease-in-out infinite alternate;
}

@keyframes slowZoom {
    0% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1.15);
    }
}

/* Enhanced hero section styling */
.hero-section {
    background-attachment: fixed;
}

.hero-content {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hero-content h1 {
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8);
}

.hero-content .bg-white\/10 {
    backdrop-filter: blur(10px) saturate(150%);
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

@media (max-width: 768px) {
    .hero-section {
        background-attachment: scroll; /* Prevent issues on mobile */
    }
    
    .hero-bg {
        animation: none; /* Disable animation on mobile for better performance */
        transform: scale(1.1);
    }
}

/* Booking Modal Styles */
#booking-modal {
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease-out;
}

#booking-modal .bg-white {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-height: 90vh;
    overflow-y: auto;
}

/* Custom scrollbar for modal */
#booking-modal .bg-white::-webkit-scrollbar {
    width: 6px;
}

#booking-modal .bg-white::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

#booking-modal .bg-white::-webkit-scrollbar-thumb {
    background: #f59e0b;
    border-radius: 3px;
}

/* Booking form inputs */
.booking-form input[type="number"]::-webkit-outer-spin-button,
.booking-form input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.booking-form input[type="number"] {
    -moz-appearance: textfield;
}

/* Counter buttons */
.increase-btn, .decrease-btn {
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.increase-btn:hover, .decrease-btn:hover {
    background-color: rgba(245, 158, 11, 0.1);
    transform: scale(1.05);
}

.increase-btn:active, .decrease-btn:active {
    transform: scale(0.95);
}

/* Modal animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Responsive modal */
@media (max-width: 768px) {
    #booking-modal .bg-white {
        margin: 1rem;
        border-radius: 1rem;
    }
    
    #booking-modal .grid-cols-3 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* Social Media Links */
.social-links a {
    transition: all 0.3s ease;
    position: relative;
}

.social-links a:hover {
    transform: translateY(-2px);
}

.social-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: currentColor;
    opacity: 0;
    border-radius: 50%;
    transform: scale(0);
    transition: all 0.3s ease;
    z-index: -1;
}

.social-links a:hover::before {
    opacity: 0.1;
    transform: scale(1.5);
}

/* Footer social media enhancements */
.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-3px) scale(1.1);
}

/* Performance Optimizations */
img {
    will-change: transform;
}

.transition-gpu {
    transform: translateZ(0);
    backface-visibility: hidden;
    perspective: 1000px;
}