/* Variables */
:root {
    --navy: #0a1e3c;
    --royal: #1a4a8a;
    --gold: #d4af37;
    --nav-height: 80px;
}

@media (max-width: 768px) {
    :root {
        --nav-height: 70px;
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Animation Classes */
.reveal {
    opacity: 0;
    transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    will-change: transform, opacity;
}

/* Desktop default offsets */
.fade-left { transform: translateX(-50px); }
.fade-right { transform: translateX(50px); }
.fade-bottom { transform: translateY(30px); }
.fade-zoom { transform: scale(0.9); }

/* Reduce offsets for mobile to prevent horizontal overflow */
@media (max-width: 768px) {
    .fade-left { transform: translateX(-20px); }
    .fade-right { transform: translateX(20px); }
    .fade-bottom { transform: translateY(20px); }

    /* 3D Slider mobile overlap fix */
    .dest-slider-wrapper { height: 450px; }
    .dest-card-3d.prev { transform: translate3d(-80px, 0, -200px) rotateY(20deg); opacity: 0.4; }
    .dest-card-3d.next { transform: translate3d(80px, 0, -200px) rotateY(-20deg); opacity: 0.4; }
}

.reveal.active {
    opacity: 1;
    transform: translate(0, 0);
}

/* Smooth floating for specific icons */
.float-anim {
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Language Switcher Button Styles */
.lang-switcher button.active {
    background-color: #e0f2fe; /* blue-100 */
    color: #1d4ed8; /* blue-700 */
}
html, body {
    max-width: 100%;
    overflow-x: hidden !important;
    position: relative;
}

body {
    font-family: 'Inter', sans-serif;
    color: #1e293b;
    line-height: 1.6;
    width: 100%; /* Ensure width is strictly 100% */
    overflow-x: hidden !important;
    scroll-behavior: smooth;
    padding-top: var(--nav-height); /* Restore padding because navbar is now white */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navbar */
.navbar {
    height: var(--nav-height);
    display: flex;
    align-items: center;
    background: white; /* Changed to solid white like mobile */
    backdrop-filter: blur(10px);
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    margin: 0;
    width: 100%;
    z-index: 1000;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.4s ease;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    font-weight: bold;
    text-decoration: none;
    color: var(--navy);
}

.logo img {
    height: 50px; /* Standardized height */
    width: auto;
    max-width: 180px;
    display: block;
    transition: all 0.3s ease;
}

.logo:hover img {
    transform: scale(1.05);
}

.menu-toggle {
    display: none;
}

.logo span { color: #f59e0b; }

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: #475569;
    font-weight: 600;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--gold);
    transition: width 0.3s ease;
}

.nav-links a:hover { color: var(--navy); }
.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    height: 95vh;
    background: linear-gradient(rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.7)), url('https://images.unsplash.com/photo-1436491865332-7a61a109c0f3?auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    text-align: center;
    color: white;
}

.hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: 64px;
    margin-bottom: 20px;
    animation: fadeInUp 0.8s ease;
}

.highlight { color: var(--gold); }

.hero p { 
    font-size: 20px; 
    max-width: 700px; 
    margin: 0 auto 40px; 
    color: #cbd5e1;
    animation: fadeInUp 0.8s ease 0.2s backwards;
}

.btn-primary, .btn-gold {
    padding: 15px 35px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
}

.btn-primary { background: var(--royal); color: white; border: none; cursor: pointer; box-shadow: 0 4px 6px rgba(26, 74, 138, 0.2); }
.btn-primary:hover { background: var(--navy); transform: translateY(-2px); box-shadow: 0 8px 15px rgba(10, 30, 60, 0.3); }

.btn-gold { background: var(--gold); color: var(--navy); box-shadow: 0 4px 6px rgba(212, 175, 55, 0.2); }
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 8px 15px rgba(212, 175, 55, 0.4); filter: brightness(1.1); }

.btn-outline { padding: 15px 35px; border: 2px solid white; color: white; text-decoration: none; border-radius: 5px; margin-left: 10px; transition: all 0.3s ease; }
.btn-outline:hover { background: white; color: var(--navy); transform: translateY(-2px); }

.btn-primary.large { padding: 20px 50px; font-size: 18px; border-radius: 50px; }

/* Stats */
footer, .footer {
    padding-bottom: 280px !important; /* ৩টি বাটনের জন্য যথেষ্ট জায়গা */
}

@media (min-width: 768px) {
    footer, .footer {
        padding-bottom: 80px !important; /* ডেস্কটপে কম প্যাডিং */
    }
}

.stats { background: var(--royal); color: white; padding: 80px 0; }
.stats .container { display: flex; justify-content: space-around; text-align: center; }
.stat-item { transition: transform 0.3s ease; }
.stat-item:hover { transform: scale(1.05); }
.stat-item i { font-size: 32px; color: var(--gold); margin-bottom: 10px; }
.stat-item h3 { font-size: 40px; color: white; }
.stat-item p { text-transform: uppercase; font-size: 12px; letter-spacing: 2px; color: #cbd5e1; }

/* About Section */
.about { padding: 100px 0; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.check-list { list-style: none; margin-top: 30px; }
.check-list li { display: flex; align-items: center; gap: 10px; margin-bottom: 15px; font-weight: 600; }
.check-list i { color: var(--gold); }
.about-image { overflow: hidden; border-radius: 10px; }
.about-image img { width: 100%; transition: transform 0.5s ease; box-shadow: 0 20px 40px rgba(0,0,0,0.1); }
.about-image:hover img { transform: scale(1.05); }

/* Services */
.services { padding: 100px 0; background: #f8fafc; }
.section-title { text-align: center; font-size: 36px; margin-bottom: 60px; font-family: 'Playfair Display', serif; }
.section-title.left { text-align: left; margin-bottom: 20px; }
.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.service-card { background: white; padding: 40px; border-radius: 5px; border-bottom: 4px solid var(--gold); box-shadow: 0 10px 30px rgba(0,0,0,0.05); text-align: center; transition: 0.3s; }
.service-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.1); border-bottom-color: var(--royal); }
.service-card i { color: var(--gold); width: 40px; height: 40px; margin-bottom: 20px; transition: transform 0.3s ease, color 0.3s ease; }
.service-card:hover i { transform: scale(1.2); color: var(--royal); }

/* Gallery Section */
.gallery { padding: 100px 0; background: #fff; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.gallery-item { 
    cursor: pointer; 
    overflow: hidden; 
    border-radius: 10px; 
    height: 350px; /* Increased height for larger cards */
    border: 1px solid #e2e8f0;
    animation: galleryReveal 0.8s cubic-bezier(0.4, 0, 0.2, 1) backwards;
    position: relative; /* For absolute positioning of country-info */
}

.country-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 15px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0));
    color: white;
    text-align: left;
}

.country-name {
    font-size: 1.5rem; /* Larger font for country name */
    font-weight: bold;
    margin-bottom: 5px;
}

.visa-type {
    font-size: 0.9rem;
    color: #f59e0b; /* Amber color for visa type */
    font-weight: 600;
}

/* Stagger Effect - একটার পর একটা ছবি আসার জন্য delay */
.gallery-item:nth-child(1) { animation-delay: 0.1s; }
.gallery-item:nth-child(2) { animation-delay: 0.2s; }
.gallery-item:nth-child(3) { animation-delay: 0.3s; }
.gallery-item:nth-child(4) { animation-delay: 0.4s; }
.gallery-item:nth-child(5) { animation-delay: 0.5s; }
.gallery-item:nth-child(6) { animation-delay: 0.6s; }

.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1); }
.gallery-item:hover img { transform: scale(1.1); filter: brightness(1.1); }

@keyframes galleryReveal {
    from { 
        opacity: 0; 
        transform: translateY(40px) scale(0.9); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0) scale(1); 
    }
}

/* Lightbox Modal */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 80px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 30, 60, 0.95);
    backdrop-filter: blur(5px);
}

.lightbox-content {
    margin: auto;
    display: block;
    width: 90%;
    max-width: 800px;
    border-radius: 5px;
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
    animation: zoom 0.4s ease;
}

@keyframes zoom {
    from {transform: scale(0.8); opacity: 0;} 
    to {transform: scale(1); opacity: 1;}
}

.close-lightbox {
    position: absolute; top: 40px; right: 40px; color: white; font-size: 50px; font-weight: 300; transition: 0.3s; cursor: pointer; line-height: 1;
}
.close-lightbox:hover { color: var(--gold); transform: rotate(90deg); }

/* Success Modal Styles */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10, 30, 60, 0.8);
    backdrop-filter: blur(8px);
    z-index: 3000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    padding: 50px;
    border-radius: 15px;
    text-align: center;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: modalSlideUp 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-icon {
    color: #25d366;
    margin-bottom: 20px;
}
.modal-icon i { width: 80px; height: 80px; }

.modal-content h2 { font-family: 'Playfair Display', serif; color: var(--navy); margin-bottom: 15px; font-size: 32px; }
.modal-content p { color: #64748b; margin-bottom: 30px; }

@keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(30px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Animated Checkmark Icon */
.success-icon-anim {
    animation: iconPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.2s both;
}

@keyframes iconPop {
    from { transform: scale(0) rotate(-45deg); opacity: 0; }
    to { transform: scale(1) rotate(0); opacity: 1; }
}

/* Testimonials */
.testimonials { padding: 100px 0; text-align: center; }
.slider-container { 
    position: relative; 
    max-width: 850px; 
    margin: 0 auto; 
    background: white;
    padding: 60px 40px;
    border-radius: 15px;
    box-shadow: 0 20px 50px rgba(10, 30, 60, 0.05);
    border: 1px solid #f1f5f9;
}
.testimonial-slide { display: none; animation: fadeIn 0.5s; }
.testimonial-slide.active { display: block; }
.stars { color: var(--gold); margin-bottom: 20px; font-size: 20px; }
.testimonial-slide p { font-style: italic; font-size: 22px; color: #475569; margin-bottom: 30px; }
.client-info strong { display: block; color: var(--navy); font-size: 18px; }
.client-info span { color: var(--gold); font-weight: bold; text-transform: uppercase; font-size: 12px; }
.slider-nav { margin-top: 40px; display: flex; justify-content: center; gap: 20px; }
.slider-nav button { background: var(--navy); color: white; border: none; width: 45px; height: 45px; border-radius: 50%; cursor: pointer; transition: 0.3s; }
.slider-nav button:hover { background: var(--gold); color: var(--navy); }

/* Contact */
.contact { padding: 100px 0; text-align: center; }
.contact-box { background: #f1f5f9; padding: 60px; border-radius: 30px; max-width: 800px; margin: 0 auto; }
.contact-box form { display: flex; flex-direction: column; gap: 15px; margin-top: 30px; }
.contact-box input { padding: 15px; border-radius: 10px; border: 1px solid #cbd5e1; outline: none; }

.error-input {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
}

/* Loading Spinner Styles */
.spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn-primary.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    pointer-events: none;
    opacity: 0.8;
}

.btn-primary.loading .spinner {
    display: block;
}

/* CTA Section */
.cta { padding: 100px 0; background: var(--navy); color: white; text-align: center; }
.cta h2 { font-size: 48px; margin-bottom: 20px; font-family: 'Playfair Display', serif; }
.cta p { margin-bottom: 40px; font-size: 18px; color: #cbd5e1; }

/* Footer */
.footer { background: #0f172a; color: #94a3b8; padding: 40px 0; text-align: center; }

/* WhatsApp Float */
.whatsapp-float {
    position: fixed; bottom: 30px; right: 30px; background: #25d366; width: 60px; height: 60px; border-radius: 50%;
    display: flex; justify-content: center; align-items: center; box-shadow: 0 10px 20px rgba(0,0,0,0.2); transition: 0.3s; z-index: 999;
}
.whatsapp-float img { width: 35px; }
.pulse { animation: pulse-animation 2s infinite; }

@keyframes pulse-animation {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Responsive */
@media (max-width: 768px) {
    .navbar {
        background: white !important; /* Force white background on mobile for logo visibility */
        display: flex;
        align-items: center;
        border-bottom: 1px solid #e2e8f0;
        box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    }

    .logo img {
        height: 40px; /* Perfect size for phone navbar */
    }
    
    .nav-links {
        display: none; 
        flex-direction: column;
        position: absolute;
        top: var(--nav-height);
        left: 0;
        width: 100%; /* Use 100% instead of 100vw to prevent horizontal scroll */
        background: white;
        padding: 20px 0;
        gap: 10px;
        text-align: center;
        border-bottom: 3px solid var(--gold);
        box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
        overflow-x: hidden;
        z-index: 999;
    }

    .nav-links.active {
        display: flex;
        animation: slideDown 0.3s ease forwards;
    }

    @keyframes slideDown {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }

    .nav-links li { width: 100%; }
    
    .nav-links a {
        display: block;
        padding: 15px 0;
        color: var(--navy);
        font-size: 18px;
        border-bottom: 1px solid #f8fafc;
    }

    .nav-links a::after { display: none; }

    .menu-toggle {
        display: block;
        cursor: pointer;
        font-size: 24px;
        position: relative;
        z-index: 1001;
        color: var(--navy);
    }

    .hero h1 { font-size: 40px; }
    .stats .container { flex-direction: column; gap: 40px; }
    .about-grid { grid-template-columns: 1fr; }
    .hero-btns { display: flex; flex-direction: column; gap: 15px; }
    .btn-outline { margin-left: 0; }
}

/* Tool specific styling */
#eligibility-wizard {
    position: relative;
}

#eligibility-wizard select option {
    background: white;
    color: #0f172a;
    padding: 10px;
}

.faq-content {
    animation: fadeIn 0.3s ease-out;
    border-top: 1px solid #f1f5f9;
}

#backToTop i {
    width: 24px;
    height: 24px;
}

#vacancy-grid .reveal {
    transition-delay: 0.1s;
}

/* Staggered Entrance for Currency Cards */
@keyframes currencyPop {
    from { opacity: 0; transform: scale(0.95) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.currency-card-anim {
    animation: currencyPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    opacity: 0;
}

/* Result Vanish & Plane Animation */
.result-fade-out {
    opacity: 0 !important;
    transform: scale(0.9) translateY(-10px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.plane-particle {
    position: absolute;
    pointer-events: none;
    z-index: 50;
    animation: planeFly 1.5s forwards ease-out;
}

@keyframes planeFly {
    0% { transform: translate(-50%, -50%) rotate(0deg) scale(0.5); opacity: 0; }
    20% { opacity: 1; }
    100% { 
        transform: translate(var(--tx), var(--ty)) rotate(var(--tr)) scale(1.2); 
        opacity: 0; 
    }
}

/* Destination Slider Fix for Mobile */
@media (max-width: 480px) {
    .dest-slider-wrapper {
        height: 350px;
        overflow: hidden;
    }
    .dest-card-3d {
        width: 220px;
        height: 300px;
    }
}

/* Premium Badge Animation */
@keyframes badgePulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 0 0 8px rgba(245, 158, 11, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
}

.badge-pulse {
    animation: badgePulse 2s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

/* How It Works Always-On Animations */
@keyframes flow-line {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.animate-flow {
    background: linear-gradient(90deg, #3b82f6, #f59e0b, #10b981, #3b82f6);
    background-size: 200% 100%;
    animation: flow-line 4s linear infinite;
}

@keyframes pulse-icon {
    0%, 100% { transform: scale(1) rotate(12deg); box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4); }
    50% { transform: scale(1.1) rotate(12deg); box-shadow: 0 0 20px 10px rgba(59, 130, 246, 0); }
}
.animate-pulse-icon { animation: pulse-icon 2s infinite; }

@keyframes float-doc {
    0%, 100% { transform: translateY(0) rotate(-12deg); }
    50% { transform: translateY(-15px) rotate(-12deg); }
}
.animate-float-doc { animation: float-doc 3s ease-in-out infinite; }

@keyframes plane-fly-small {
    0% { transform: translate(-2px, 2px) rotate(12deg); }
    50% { transform: translate(5px, -5px) rotate(15deg); }
    100% { transform: translate(-2px, 2px) rotate(12deg); }
}
.animate-plane-fly { animation: plane-fly-small 2.5s ease-in-out infinite; }

.step-card-glass {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-card-glass:hover {
    background: white;
    transform: translateY(-15px) scale(1.02);
}