@import url('https://fonts.googleapis.com/css2?family=Fira+Sans:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Montserrat+Underline:ital,wght@0,100..900;1,100..900&family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap');

html,
body {
    /* height: 100%; */
    margin: 0;
    padding: 0;
    -webkit-overflow-scrolling: touch;
    /* For smooth scrolling on iOS */


}

.footer-section .ancer {
    text-decoration: none;
    color: var(--primary-color);
}

* {
    -webkit-text-size-adjust: 100%;
    /* touch-action: manipulation; */
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s;
}

body {
    position: relative;
    padding: 0;
    margin: 0;
    line-height: 1.5;
    font-family: "Ubuntu", sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    padding: 2rem 0;
    box-sizing: border-box;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

:root {
    --primary-color: #98bbf5;
    --secondary-color: #1c304f;
    --accent-color: #4a90e2;
    --background-color: #ffffff;
    --text-color: #1c304f;
    --card-background: #f8faff;
    --border-color: #98bbf5;
}

[data-theme="dark"] {
    --primary-color: #98bbf5;
    --secondary-color: #1c304f;
    --accent-color: #4a90e2;
    --background-color: #0a1625;
    --text-color: #ffffff;
    --card-background: #1c304f;
    --border-color: #98bbf5;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 1rem 1rem 1rem;
    /* Added top padding for fixed navbar */
    /* overflow: auto; */
    position: relative;
}

.header {

    margin-top: 3.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

/* Updated Theme Toggle Button */
.theme-toggle {
    position: relative;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(145deg, #e6e6e6, #ffffff);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow:
        -8px -4px 8px 0px rgba(255, 255, 255, 0.8),
        8px 4px 12px 0px rgba(0, 0, 0, 0.15),
        inset 0px 0px 0px 0px rgba(255, 255, 255, 0.4),
        inset 0px 0px 0px 0px rgba(0, 0, 0, 0.4);
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow:
        -10px -6px 12px 0px rgba(255, 255, 255, 0.9),
        10px 6px 15px 0px rgba(0, 0, 0, 0.2);
}

/* Icon Styles */
.theme-toggle .sun-icon,
.theme-toggle .moon-icon {
    position: absolute;
    width: 24px;
    height: 24px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-toggle .sun-icon {
    opacity: 1;
    transform: rotate(0deg) scale(1);
}

.theme-toggle .moon-icon {
    opacity: 0;
    transform: rotate(90deg) scale(0);
}

.theme-toggle .sun-icon::before {
    content: '☀️';
    font-size: 24px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.theme-toggle .moon-icon::before {
    content: '🌙';
    font-size: 22px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Dark Theme Styles */
[data-theme="dark"] .theme-toggle {
    background: linear-gradient(145deg, #1a1a1a, #2c2c2c);
    box-shadow:
        -8px -4px 8px 0px rgba(255, 255, 255, 0.05),
        8px 4px 12px 0px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .theme-toggle .sun-icon {
    opacity: 0;
    transform: rotate(-90deg) scale(0);
}

[data-theme="dark"] .theme-toggle .moon-icon {
    opacity: 1;
    transform: rotate(0deg) scale(1);
}

/* Click Animation */
.theme-toggle:active {
    transform: scale(0.95);
    box-shadow:
        -4px -2px 4px 0px rgba(255, 255, 255, 0.6),
        4px 2px 6px 0px rgba(0, 0, 0, 0.3),
        inset 2px 2px 3px 0px rgba(0, 0, 0, 0.1),
        inset -2px -2px 3px 0px rgba(255, 255, 255, 0.7);
}

/* Icon Transition Animation */
@keyframes iconSpin {
    0% {
        transform: rotate(0deg) scale(1);
    }

    50% {
        transform: rotate(180deg) scale(0.5);
    }

    100% {
        transform: rotate(360deg) scale(1);
    }
}

.theme-toggle.switching .sun-icon,
.theme-toggle.switching .moon-icon {
    animation: iconSpin 0.5s ease-in-out;
}

/* Glow Effect */
.theme-toggle::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: linear-gradient(45deg,
            rgba(255, 255, 0, 0.2),
            rgba(255, 255, 255, 0.2));
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.theme-toggle:hover::after {
    opacity: 1;
}

[data-theme="dark"] .theme-toggle::after {
    background: linear-gradient(45deg,
            rgba(70, 130, 180, 0.2),
            rgba(25, 25, 112, 0.2));
}

/* Particle Effects */
.particles {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 50%;
    opacity: 0;
    animation: particle-animation 0.8s ease-out;
}

@keyframes particle-animation {
    0% {
        opacity: 1;
        transform: scale(0) translate(0, 0);
    }

    100% {
        opacity: 0;
        transform: scale(1) translate(var(--tx), var(--ty));
    }
}

/* Glow Effect */
.theme-toggle::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50px;
    background: linear-gradient(45deg,
            rgba(var(--primary-rgb), 0.2),
            rgba(var(--accent-rgb), 0.2));
    filter: blur(15px);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.theme-toggle:hover::after {
    opacity: 1;
}

/* Ripple Effect */
.theme-toggle .ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: scale(0);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Stars and Clouds Animation */
.theme-toggle .stars,
.theme-toggle .clouds {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.theme-toggle .star {
    position: absolute;
    background: #fff;
    border-radius: 50%;
    animation: twinkle 1s infinite;
}

.theme-toggle .cloud {
    position: absolute;
    background: #fff;
    border-radius: 10px;
    animation: float 3s infinite;
}

@keyframes twinkle {
    50% {
        opacity: 0.3;
    }
}

@keyframes float {
    50% {
        transform: translateY(-2px);
    }
}

[data-theme="dark"] .theme-toggle .stars {
    opacity: 1;
}

[data-theme="light"] .theme-toggle .clouds {
    opacity: 1;
}

/* Enhanced Upload Container with Animated Border */
.upload-container {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 3rem 2rem;
    text-align: center;
    margin-bottom: 2rem;
    cursor: pointer;
    position: relative;
    /* overflow: hidden; */
    border-radius: 24px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.1),
        inset 0 0 32px rgba(255, 255, 255, 0.1);
    z-index: 1;
}

/* Glassmorphic inner container */
.upload-container::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 22px;
    z-index: -1;
}

@keyframes moveGradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

Hover effects .upload-container:hover {
    transform: translateY(-5px);
    box-shadow:
        0 15px 40px rgba(0, 0, 0, 0.15),
        inset 0 0 40px rgba(255, 255, 255, 0.15);
}

.upload-container:hover::before {
    animation: moveGradient 4s linear infinite;
    filter: brightness(1.2);
}

/* Dark mode adjustments */
[data-theme="dark"] .upload-container {
    background: rgba(28, 48, 79, 0.3);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 0 32px rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .upload-container::after {
    background: rgba(28, 48, 79, 0.4);
}

/* Drag over animation */
.upload-container.dragover::before {
    animation: moveGradient 2s linear infinite;
    filter: brightness(1.4);
}

.upload-container.dragover {
    transform: scale(1.02);
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.2),
        inset 0 0 50px rgba(255, 255, 255, 0.2);
}

/* Content animations */
.upload-icon,
.upload-text,
.supported-formats {
    position: relative;
    z-index: 2;
}

.upload-container p {
    color: var(--text-color);
    font-size: 1.1rem;
    margin: 1rem 0;
    opacity: 0.9;
    transform: translateY(0);
    transition: all 0.3s ease;
}

.upload-container:hover p {
    transform: translateY(-3px);
    opacity: 1;
}

/* Upload Icon Animation */
.upload-icon {
    position: relative;
    display: inline-block;
    margin-bottom: 2rem;
}

.upload-icon i {
    font-size: 4rem;
    background: linear-gradient(45deg, #00000078, #ffffff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.upload-container:hover .upload-icon i {
    transform: scale(1.1) translateY(-5px);
}

/* Animated ring around upload icon */
.upload-animation {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100px;
    height: 100px;
    border: 3px dashed var(--primary-color);
    border-radius: 50%;
    opacity: 0.5;
    animation: spin 10s linear infinite;
}

@keyframes spin {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Modern Upload Text */
.upload-text {
    margin-bottom: 2rem;
}

.upload-text h3 {
    font-size: 1.8rem;
    color: var(--text-color);
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.upload-text p {
    color: var(--text-color);
    font-size: 1.1rem;
    opacity: 0.8;
    transition: all 0.3s ease;
}

/* Enhanced Browse Text Styles */
.browse-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.5rem;
    margin: 0 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(152, 187, 245, 0.1);
    border: 1px solid rgba(152, 187, 245, 0.2);
    border-radius: 30px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
}

/* Gradient background animation */
.browse-text::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg,
            var(--primary-color),
            var(--accent-color),
            var(--primary-color));
    background-size: 200% 100%;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

/* Shine effect */
.browse-text::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(transparent,
            rgba(255, 255, 255, 0.2),
            transparent);
    transform: rotate(45deg) translateX(-100%);
    transition: transform 0.6s ease;
}

/* Text container for proper layering */
.browse-text span {
    position: relative;
    z-index: 2;
}

/* Hover animations */
.browse-text:hover {
    color: white;
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 5px 20px rgba(152, 187, 245, 0.3);
    border-color: transparent;
}

.browse-text:hover::before {
    opacity: 1;
    animation: gradientMove 2s linear infinite;
}

.browse-text:hover::after {
    transform: rotate(45deg) translateX(100%);
    transition: transform 0.8s ease;
}

/* Active state */
.browse-text:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 2px 5px rgba(152, 187, 245, 0.2);
}

/* Dark mode adjustments */
[data-theme="dark"] .browse-text {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .browse-text:hover {
    box-shadow: 0 5px 20px rgba(152, 187, 245, 0.2);
}

/* Gradient animation */
@keyframes gradientMove {
    0% {
        background-position: 100% 0%;
    }

    100% {
        background-position: -100% 0%;
    }
}

/* Remove previous underline animation */
.browse-text::after {
    content: none;
}

/* Modern Format Tags */
.supported-formats {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.format {
    padding: 0.6rem 1.2rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(0);
}

[data-theme="dark"] .format {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.format:hover {
    transform: translateY(-5px);
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    color: white;
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Drag over state animation */
.upload-container.dragover {
    transform: scale(1.02);
    border-color: var(--accent-color);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.15),
        inset 0 0 40px rgba(255, 255, 255, 0.15);
}

.upload-container.dragover .upload-animation {
    animation: spin 5s linear infinite;
    opacity: 0.8;
}

/* File Type Badges */
.supported-formats {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.format {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    transform: translateY(0);
}

.format:hover {
    transform: translateY(-3px) scale(1.05);
    background: var(--primary-color);
    color: white;
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Mouse Follow Effect */
.upload-container {
    --mouse-x: 50%;
    --mouse-y: 50%;
}

/* Add this JavaScript to your navbar.js file to enable the mouse follow effect */
/* 
document.querySelector('.upload-container').addEventListener('mousemove', (e) => {
    const bounds = e.target.getBoundingClientRect();
    const x = ((e.clientX - bounds.left) / bounds.width) * 100;
    const y = ((e.clientY - bounds.top) / bounds.height) * 100;
    e.target.style.setProperty('--mouse-x', `${x}%`);
    e.target.style.setProperty('--mouse-y', `${y}%`);
});
*/

.upload-icon {
    position: relative;
    display: inline-block;
    margin-bottom: 1.5rem;
}

.upload-icon i {
    font-size: 4rem;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.upload-container:hover .upload-icon i {
    transform: scale(1.1) translateY(-5px);
}

.upload-animation {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    border: 3px dashed var(--primary-color);
    border-radius: 50%;
    opacity: 0;
    transition: all 0.3s ease;
}

.upload-container:hover .upload-animation {
    animation: rotate 10s linear infinite;
    opacity: 0.2;
}

@keyframes rotate {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.upload-text {
    margin-bottom: 1.5rem;
}

.upload-text h3 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.upload-text p {
    color: var(--text-color);
    opacity: 0.8;
}

.browse-text {
    color: var(--primary-color);
    text-decoration: none;
    position: relative;
    cursor: pointer;
    padding-bottom: 2px;
    font-weight: 600;
}

.browse-text::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.browse-text:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

.supported-formats {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.format {
    padding: 0.5rem 1rem;
    background: rgba(152, 187, 245, 0.1);
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    transition: all 0.3s ease;
}

.format:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

/* Drag over state */
.upload-container.dragover {
    border-color: var(--accent-color);
    background: rgba(152, 187, 245, 0.1);
    transform: scale(1.02);
}

.upload-container.dragover .upload-icon i {
    transform: scale(1.2);
    color: var(--accent-color);
}

.upload-container.dragover .upload-animation {
    opacity: 0.3;
    animation: rotate 5s linear infinite;
}

/* File input styling */
#fileInput {
    display: none;
}

/* Enhanced Preview Container */
.preview-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-top: 3rem;
    position: relative;
    perspective: 1000px;
}

/* Modern Preview Card with Glassmorphism */
.preview-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: visible;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.1),
        inset 0 0 32px rgba(255, 255, 255, 0.1);
}

/* Card Hover Effects */
.preview-card:hover {
    transform: translateY(-10px) rotateX(2deg) rotateY(2deg);
    box-shadow:
        0 15px 40px rgba(0, 0, 0, 0.15),
        inset 0 0 50px rgba(255, 255, 255, 0.15);
}

/* Card Title Styles */
.preview-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
}

/* Title underline animation */
.preview-card h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s ease;
}

.preview-card:hover h3::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Image Preview Styles */
.image-preview {
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
    border-radius: 16px;
    margin: 1.5rem 0;
    transition: all 0.4s ease;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2));
}

.preview-card:hover .image-preview {
    transform: scale(1.02);
    filter: drop-shadow(0 8px 25px rgba(0, 0, 0, 0.3));
}

/* Enhanced Download Button */
.download-btn {
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 1.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Button shine effect */
.download-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(transparent,
            rgba(255, 255, 255, 0.3),
            transparent);
    transform: rotate(45deg) translateX(-100%);
    transition: transform 0.6s ease;
}

.download-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.download-btn:hover::before {
    transform: rotate(45deg) translateX(100%);
}

/* Dark mode adjustments */
[data-theme="dark"] .preview-card {
    background: rgba(28, 48, 79, 0.3);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .preview-card:hover {
    box-shadow:
        0 15px 40px rgba(0, 0, 0, 0.3),
        inset 0 0 50px rgba(255, 255, 255, 0.05);
}

/* Loading animation */
.preview-card.loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.1),
            transparent);
    animation: loadingShimmer 1.5s infinite;
}

@keyframes loadingShimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .preview-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .preview-card {
        padding: 1.5rem;
    }

    .preview-card:hover {
        transform: translateY(-5px);
    }

    .container {
        width: 100%;
        min-width: 320px;
        /* Ensures minimum width when zoomed */
        overflow-x: hidden;
    }

    .preview-container {
        width: 100%;
        padding: 0 10px;
        box-sizing: border-box;
    }

    .upload-container {
        width: 100%;
        min-height: 200px;
        padding: 20px;
        box-sizing: border-box;
    }

    .nav-links {
        position: fixed;
        top: 60px;
        /* Adjust based on your navbar height */
        left: 0;
        right: 0;
        bottom: 0;
        height: calc(100vh - 60px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    body.menu-open {
        overflow: hidden;
    }

    .upload-container,
    .preview-container,
    .about-tool,
    .footer {
        width: 100%;
        overflow: visible;
        transform: none;
    }
}

.preview-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.preview-card {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 1rem;
    text-align: center;
}

.image-preview {
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
    border-radius: 5px;
    margin: 1rem 0;
}

.download-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 1rem;
    display: none;
}

.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@media (max-width: 768px) {
    .preview-container {
        grid-template-columns: 1fr;
    }
}

/* Updated Footer Styles */
.footer {
    background: var(--secondary-color);
    padding: 4rem 2rem 6rem;
    margin-top: 4rem;
    position: relative;
    overflow: hidden;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1.5fr 1fr 1.5fr;
    gap: 3rem;
    position: relative;
    z-index: 1;
}

.footer-section {
    color: var(--primary-color);
}

.footer-section h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    position: relative;
    display: inline-block;
}

.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    color: var(--primary-color);
    opacity: 0.9;
    transition: all 0.3s ease;
}

.footer-contact li:hover {
    opacity: 1;
    transform: translateX(5px);
}

.footer-contact i {
    width: 20px;
    text-align: center;
}

.social-heading {
    margin-top: 2rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 3rem;
    border-top: 1px solid rgba(152, 187, 245, 0.2);
    position: relative;
    z-index: 1;
}

.copyright {
    color: var(--primary-color);
    opacity: 0.8;
}

.copyright p {
    font-size: 0.9rem;
}

.copyright i {
    color: #ff4d4d;
    margin: 0 3px;
}

/* Responsive Footer */
@media (max-width: 1200px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 3rem 1rem 5rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }

    .footer-section h3 {
        margin-left: auto;
        margin-right: auto;
    }

    .footer-contact li {
        justify-content: center;
    }

    .footer-contact li:hover {
        transform: translateY(-3px);
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 2rem 1rem 4rem;
    }

    .copyright p {
        font-size: 0.8rem;
    }
}

/* Update existing footer wave for better visibility */
.footer-wave {
    opacity: 0.15;
}

/* New Footer Styles */
.footer {
    background: var(--secondary-color);
    padding: 3rem 2rem 5rem;
    margin-top: 4rem;
    position: relative;
    overflow: hidden;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    position: relative;
    z-index: 1;
}

.leftforalign {
    margin-left: 50px;
    display: grid;
    place-items: left;
    text-align: left;
}

.footer-section {
    color: var(--primary-color);
}

.footer-section h3 {
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.footer-section:hover h3::after {
    width: 40%;
}

.footer-section p {
    color: var(--primary-color);
    opacity: 0.8;
    line-height: 1.6;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    display: inline-block;
    margin: 5px 0;
}

/* .footer-section p::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 1px;
    background: var(--primary-color);
    bottom: 0;
    left: 0;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
} */

.footer-section p:hover {
    opacity: 1;
    transform: translateX(5px);
    color: var(--accent-color);
}

.footer-section p:hover::before {
    transform: scaleX(1);
    transform-origin: left;
}

.footer-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='%2398bbf5' fill-opacity='0.4' d='M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,112C672,96,768,96,864,112C960,128,1056,160,1152,160C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E");
    background-size: 50% 100%;
    background-repeat: repeat-x;
    animation: waveMove 30s linear infinite;
}

.footer-wave::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='%2398bbf5' fill-opacity='0.2' d='M0,128L48,144C96,160,192,192,288,192C384,192,480,160,576,144C672,128,768,128,864,144C960,160,1056,192,1152,192C1248,192,1344,160,1392,144L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E");
    background-size: 50% 100%;
    background-repeat: repeat-x;
    animation: waveMove 20s linear infinite;
    opacity: 0.7;
}

@keyframes waveMove {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Desktop optimization */
@media (min-width: 1024px) {
    .footer-wave {
        height: 150px;
        background-size: 50% 150px;
    }

    .footer-wave::before {
        height: 150px;
        background-size: 50% 150px;
    }
}

/* Social Icons Styles */
.social-icons {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
    justify-content: center;
}

.social-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 1.2rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.social-icon::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: var(--accent-color);
    border-radius: 50%;
    transform: scale(0);
    transition: transform 0.3s ease;
    z-index: 1;
}

.social-icon i {
    position: relative;
    z-index: 2;
    transition: color 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-5px);
}

.social-icon:hover::before {
    transform: scale(1);
}

.social-icon:hover i {
    color: #ffffff;
}

/* Individual social icon hover colors */
.social-icon:nth-child(1):hover::before {
    background: #1877f2;
    /* Facebook */
}

.social-icon:nth-child(2):hover::before {
    background: #e4405f;
    /* Instagram */
}

.social-icon:nth-child(3):hover::before {
    background: #0077b5;
    /* LinkedIn */
}

.social-icon:nth-child(4):hover::before {
    background: #333333;
    /* GitHub */
}

/* Add this to existing media query */
@media (max-width: 768px) {
    .social-icons {
        justify-content: center;
        flex-wrap: wrap;
    }
}

/* Quick Links Special Animation */
.footer-section:nth-child(2) p {
    padding-left: 0;
    transition: all 0.3s ease;
}

.footer-section:nth-child(2) p::before {
    content: '→';
    position: absolute;
    left: -20px;
    opacity: 0;
    transition: all 0.3s ease;
}

.footer-section:nth-child(2) p:hover {
    padding-left: 20px;
}

.footer-section:nth-child(2) p:hover::before {
    opacity: 1;
    left: 0;
}

/* About Section Text Animation */
.footer-section:first-child p {
    position: relative;
    transition: all 0.3s ease;
}

.footer-section:first-child p:hover {
    transform: translateY(-5px);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

/* Add these styles for better mobile menu */
body.menu-open {
    overflow: hidden;
}

/* Update footer responsive styles */
@media (max-width: 1024px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 3rem;
        padding: 0 1rem;
    }

    .footer-section {
        text-align: left;
    }

    .leftforalign {
        margin-left: 0;
    }

    .social-icons {
        justify-content: flex-start;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 3rem 1rem 6rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .footer-section {
        text-align: center;
    }

    .footer-section h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-section p {
        font-size: 1.1rem;
    }

    .social-icons {
        justify-content: center;
        gap: 2rem;
    }

    .social-icon {
        width: 50px;
        height: 50px;
        font-size: 1.4rem;
    }

    .footer-wave {
        height: 80px;
    }

    .leftforalign {
        text-align: center;
        place-items: center;
    }

    /* Quick Links animation update for mobile */
    .footer-section:nth-child(2) p::before {
        display: none;
    }

    .footer-section:nth-child(2) p:hover {
        padding-left: 0;
        transform: scale(1.1);
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 2rem 1rem 5rem;
    }

    .footer-content {
        gap: 2rem;
    }

    .footer-section h3 {
        font-size: 1.3rem;
    }

    .footer-section p {
        font-size: 1rem;
    }

    .social-icons {
        gap: 1.5rem;
    }

    .social-icon {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }

    .footer-wave {
        height: 60px;
    }
}

/* About Tool Section Styles */
.about-tool {
    padding: 2rem 0;
    /* margin-bottom: 3rem; */
    background: linear-gradient(145deg, var(--card-background), var(--background-color));
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.about-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.about-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--text-color);
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.about-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60%;
    height: 3px;
    background: var(--primary-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.about-tool:hover .about-title::after {
    transform: scaleX(1);
}

.about-features {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin: 3rem 0;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    border-radius: 10px;
    background: var(--background-color);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transform: translateY(0);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.feature-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.feature-card:hover i {
    transform: scale(1.2);
    color: var (--accent-color);
}

.feature-card h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var (--text-color);
}

.feature-card p {
    color: var(--text-color);
    opacity: 0.8;
    line-height: 1.6;
}

.about-description {
    text-align: center;
    line-height: 1.8;
    color: var(--text-color);
    opacity: 0.9;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
    border-radius: 10px;
    background: var(--background-color);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transform: translateY(0);
    transition: all 0.3s ease;
}

.about-description:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Responsive Design for About Section */
@media (max-width: 1024px) {
    .about-features {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .about-tool {
        padding: 2rem 1rem;
    }

    .about-title {
        font-size: 2rem;
    }

    .about-features {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .feature-card {
        padding: 1.5rem;
    }

    .feature-card i {
        font-size: 2rem;
    }

    .about-description {
        padding: 1.5rem;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .about-tool {
        padding: 1.5rem 1rem;
    }

    .about-title {
        font-size: 1.8rem;
    }

    .feature-card {
        padding: 1rem;
    }

    .feature-card i {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }

    .feature-card h3 {
        font-size: 1.1rem;
    }

    .about-description {
        padding: 1rem;
        font-size: 0.9rem;
    }
}

/* Footer Links Styles */
.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
    opacity: 0.8;
    position: relative;
    padding-left: 0;
}

.footer-links a:hover {
    color: var(--accent-color);
    opacity: 1;
    padding-left: 20px;
}

.footer-links a::before {
    content: '→';
    position: absolute;
    left: -20px;
    opacity: 0;
    transition: all 0.3s ease;
}

.footer-links a:hover::before {
    opacity: 1;
    left: 0;
}

@media (max-width: 768px) {
    .footer-links {
        text-align: center;
    }

    .footer-links a:hover {
        padding-left: 0;
    }

    .footer-links a::before {
        display: none;
    }
}

/* Additional Responsive Styles */
@media (max-width: 1024px) {
    .container {
        padding: 1rem;
    }

    .about-features {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .feature-card {
        padding: 1.5rem;
    }
}

@media (max-width: 768px) {
    .container {
        margin: 60px auto 0;
        padding: 1rem;
    }

    .header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .header h1 {
        font-size: 1.8rem;
    }

    .preview-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .upload-container {
        padding: 2rem 1rem;
    }

    .upload-text h3 {
        font-size: 1.2rem;
    }

    .supported-formats {
        flex-wrap: wrap;
        justify-content: center;
    }

    .about-features {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .about-title {
        font-size: 1.8rem;
    }

    .about-description {
        padding: 1rem;
        font-size: 0.95rem;
    }

    .browse-text {
        padding: 1rem 2rem;
        margin: 0.5rem;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    body {
        padding: 0.5rem;
    }

    .container {
        padding: 0.5rem;
    }

    .header h1 {
        font-size: 1.5rem;
    }

    .upload-container {
        padding: 1.5rem 0.5rem;
    }

    .upload-text h3 {
        font-size: 1.1rem;
    }

    .format {
        padding: 0.3rem 0.6rem;
        font-size: 0.8rem;
    }

    .preview-card {
        padding: 0.5rem;
    }

    .download-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }

    .feature-card {
        padding: 1rem;
    }

    .feature-card i {
        font-size: 2rem;
    }

    .feature-card h3 {
        font-size: 1.1rem;
    }

    .about-title {
        font-size: 1.5rem;
    }

    .about-description {
        font-size: 0.9rem;
        padding: 0.8rem;
    }

    .nav-links li a,
    .browse-text,
    .download-btn,
    .theme-toggle {
        min-height: 44px;
        /* Minimum touch target size */
        min-width: 44px;
        padding: 12px 20px;
    }

    .format {
        padding: 8px 16px;
        margin: 4px;
    }
}

/* Touch Device Optimizations */
@media (hover: none) {
    .upload-container:hover {
        transform: none;
    }

    .feature-card:hover {
        transform: none;
    }

    .social-icon:hover {
        transform: none;
    }

    .browse-text:active {
        transform: scale(0.95);
        background: var(--primary-color);
        color: white;
    }
}

/* Advanced Navbar Styles */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: auto;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow:
        0 4px 30px rgba(0, 0, 0, 0.1),
        inset 0 0 30px rgba(255, 255, 255, 0.1);
    z-index: 1000;
    transform-origin: top;
    transition: all 0.4s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(120deg,
            rgba(255, 255, 255, 0.2) 0%,
            rgba(255, 255, 255, 0.05) 50%,
            rgba(255, 255, 255, 0) 100%);
    pointer-events: none;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
}

.nav-content {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
}

/* Updated Logo Styles */
.logo {
    position: relative;
    z-index: 1;
}



@keyframes gradientMove {
    0% {
        background-size: 200% 200%;
        background-position: 0% 50%;
    }

    50% {
        background-size: 200% 200%;
        background-position: 100% 50%;
    }

    100% {
        background-size: 200% 200%;
        background-position: 0% 50%;
    }
}

.logo a {
    font-family: "Montserrat Underline", sans-serif;
    padding: 10px 20px;
    border-radius: 8px;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 100;
    background: linear-gradient(180deg, #4a90e2, #9b51e0, #6e48aa, #2196f3);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientFlow 8s ease infinite;
}

.logo i {
    font-size: 1.8rem;
    margin-right: 0.5rem;
    background: linear-gradient(45deg, #4a90e2, #9b51e0, #6e48aa, #2196f3);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientFlow 8s ease infinite;
    transition: all 0.3s ease;
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    transition: transform 0.5s cubic-bezier(0.645, 0.045, 0.355, 1),
        opacity 0.4s ease,
        visibility 0.4s ease;
}

.nav-links li a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.nav-links li a i {
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.nav-links li a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary-color);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.nav-links li a:hover {
    color: var(--primary-color);
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.1),
        inset 0 0 10px rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.nav-links li a:hover::before {
    transform: translateX(0);
}

.nav-links li a:hover i {
    transform: translateY(-3px);
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #000, #ffffff64);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.nav-links li a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    cursor: pointer;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 50px;
    height: 50px;
    position: relative;
    background: transparent;
    border: none;
    cursor: pointer;
    display: none;
    outline: none;
}

.hamburger {
    width: 25px;
    height: 3px;
    background: var(--secondary-color);
    position: relative;
    transition: all 0.3s ease;
    width: 30px;
    height: 2px;
    background: var(--secondary-color);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 3px;
    background: var(--secondary-color);
    transition: all 0.3s ease;
    content: '';
    width: 30px;
    height: 2px;
    background: var(--secondary-color);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.hamburger::before {
    transform: translateY(-8px);
    content: '';
    top: -8px;
}

.hamburger::after {
    transform: translateY(8px);
    content: '';
    top: 8px;
}

/* Mobile Menu Active States */
.menu-toggle.active .hamburger {
    background: transparent;
}

.menu-toggle.active .hamburger::before {
    transform: rotate(45deg);
}

.menu-toggle.active .hamburger::after {
    transform: rotate(-45deg);
}

/* Mobile Menu Active States */
.menu-open .hamburger {
    background: transparent;
}

.menu-open .hamburger::before {
    transform: translate(-50%, 8px) rotate(45deg);
}

.menu-open .hamburger::after {
    transform: translate(-50%, -8px) rotate(-45deg);
}

/* Responsive Design */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 72px;
        left: 0;
        width: 100%;
        background: rgb(255, 255, 255);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border: 1px solid rgba(255, 255, 255, 0.2);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        flex-direction: column;
        gap: 0;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        height: calc(100vh - 80px);
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        padding: 2rem;
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        overflow-y: auto;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links li a {
        padding: 1rem 2rem;
        border-radius: 0;
        justify-content: flex-start;
        width: 100%;
        text-align: center;
        padding: 1rem;
        border-radius: 8px;
        transform: scale(0.95);
        transition: all 0.3s ease;
    }

    .nav-links li a::before {
        display: none;
    }

    .nav-links li a:hover {
        background: var(--primary-color);
        color: white;
        transform: scale(1);
        background: rgba(var(--accent-color), 0.1);
    }

    .nav-links li a:hover i {
        transform: none;
        color: white;
    }

    [data-theme="dark"] .nav-links {
        background: rgba(0, 0, 0, 0.8);
        border-color: rgba(255, 255, 255, 0.05);
    }

    .menu-toggle {
        background: rgba(255, 255, 255, 0.1);
        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-links li {
        width: 100%;
        transform: translateY(-20px);
        opacity: 0;
        transition: all 0.3s ease;
    }

    .nav-links.active li {
        transform: translateY(0);
        opacity: 1;
    }

    .nav-links li:nth-child(1) {
        transition-delay: 0.1s;
    }

    .nav-links li:nth-child(2) {
        transition-delay: 0.2s;
    }

    .nav-links li:nth-child(3) {
        transition-delay: 0.3s;
    }

    .nav-links li:nth-child(4) {
        transition-delay: 0.4s;
    }
}

@media (max-width: 480px) {
    .nav-content {
        padding: 1rem;
    }

    .logo a {
        font-size: 1.3rem;
    }

    .nav-links li a {
        padding: 0.8rem;
        font-size: 0.85rem;
    }
}

/* Navbar Animation for Page Load */
@keyframes navFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar {
    animation: navFadeIn 0.5s ease forwards;
}

.nav-links li {
    opacity: 0;
    animation: navFadeIn 0.5s ease forwards;
}

.nav-links li:nth-child(1) {
    animation-delay: 0.1s;
}

.nav-links li:nth-child(2) {
    animation-delay: 0.2s;
}

.nav-links li:nth-child(3) {
    animation-delay: 0.3s;
}

.nav-links li:nth-child(4) {
    animation-delay: 0.4s;
}

/* Updated Navbar Styles with Glassmorphism */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgb(255, 255, 255);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

/* Enhanced Logo Animation */
.logo a {
    background: linear-gradient(45deg, #FF6B6B, #4ECDC4, #45B7D1, #96E6A1);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientFlow 8s ease infinite;
    font-weight: 700;
    font-size: 1.6rem;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo a::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    transform: scale(0);
    transition: transform 0.3s ease;
}

.logo:hover a::before {
    transform: scale(1);
}

/* Updated Navigation Links */
.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links li a {
    color: var(--secondary-color);
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-links li a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg,
            rgba(255, 107, 107, 0.2),
            rgba(78, 205, 196, 0.2),
            rgba(69, 183, 209, 0.2),
            rgba(150, 230, 161, 0.2));
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    z-index: -1;
}

.nav-links li a:hover {
    color: var(--accent-color);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.nav-links li a:hover::before {
    transform: translateX(0);
}

.nav-links li a i {
    transition: transform 0.3s ease;
}

.nav-links li a:hover i {
    transform: rotate(360deg);
}

/* Mobile Menu Styles */
.menu-toggle {
    display: none;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.8rem;
    border-radius: 8px;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}

.hamburger,
.hamburger::before,
.hamburger::after {
    width: 25px;
    height: 2px;
    background: var(--secondary-color);
    transition: all 0.3s ease;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .nav-links li a {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.9);
        backdrop-filter: blur(10px);
        padding: 1rem;
        flex-direction: column;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links li a {
        width: 100%;
        display: flex;
        justify-content: center;
        padding: 1rem;
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.1);
    }

    .nav-links li a:hover {
        background: rgba(var(--accent-color), 0.1);
    }

    .menu-toggle.active .hamburger {
        background: transparent;
    }

    .menu-toggle.active .hamburger::before {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .menu-toggle.active .hamburger::after {
        transform: rotate(-45deg) translate(5px, -5px);
    }
}

@media (max-width: 480px) {
    .nav-content {
        padding: 1rem;
    }

    .logo a {
        font-size: 1.3rem;
    }

    .nav-links li a {
        padding: 0.8rem;
        font-size: 0.85rem;
    }
}

/* Dark Mode Adjustments */
[data-theme="dark"] .navbar {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .navbar::before {
    background: linear-gradient(120deg,
            rgba(255, 255, 255, 0.05) 0%,
            rgba(255, 255, 255, 0.02) 50%,
            rgba(255, 255, 255, 0) 100%);
}

[data-theme="dark"] .nav-links li a {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .nav-links li a:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

/* Updated Navbar Background Styles */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.98), rgba(248, 250, 255, 0.98));
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(120deg,
            rgba(255, 255, 255, 0.1),
            rgba(248, 250, 255, 0.05));
    pointer-events: none;
}

/* Dark Theme Navbar */
[data-theme="dark"] .navbar {
    background: linear-gradient(to right, rgba(28, 48, 79, 0.98), rgba(10, 22, 37, 0.98));
    border-color: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .navbar::before {
    background: linear-gradient(120deg,
            rgba(0, 0, 0, 0.2),
            rgba(28, 48, 79, 0.15));
}

/* Mobile Navigation Background */
@media (max-width: 768px) {
    .nav-links {
        background: linear-gradient(to bottom, rgba(255, 255, 255, 0.98), rgba(248, 250, 255, 0.98));
    }

    [data-theme="dark"] .nav-links {
        background: linear-gradient(to bottom, rgba(28, 48, 79, 0.98), rgba(10, 22, 37, 0.98));
    }

    .nav-links li a {
        background: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(0, 0, 0, 0.05);
    }

    [data-theme="dark"] .nav-links li a {
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
}

/* Light Mode Navbar */
.navbar {
    background: #ffffff;
    border-bottom: 1px solid rgba(152, 187, 245, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.nav-links li a {
    background: rgba(152, 187, 245, 0.1);
    color: var(--secondary-color);
    border: 1px solid rgba(152, 187, 245, 0.2);
}

.nav-links li a:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Dark Mode Styles */
[data-theme="dark"] {
    /* ...existing dark theme variables... */
}

[data-theme="dark"] .navbar {
    background: #1c304f;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .nav-links li a {
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .nav-links li a:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

[data-theme="dark"] .theme-toggle {
    background: #2c4366;
    color: #ffffff;
}

/* Mobile Responsive Navbar Colors */
@media (max-width: 768px) {
    .navbar {
        background: #ffffff;
    }

    .nav-links {
        background: #ffffff;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    }

    .nav-links li a {
        background: rgba(152, 187, 245, 0.1);
        border: 1px solid rgba(152, 187, 245, 0.2);
    }

    [data-theme="dark"] .navbar {
        background: #1c304f;
    }

    [data-theme="dark"] .nav-links {
        background: #1c304f;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    }

    [data-theme="dark"] .nav-links li a {
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .hamburger,
    .hamburger::before,
    .hamburger::after {
        background: var(--secondary-color);
    }

    [data-theme="dark"] .hamburger,
    [data-theme="dark"] .hamburger::before,
    [data-theme="dark"] .hamburger::after {
        background: #ffffff;
    }
}

@media screen and (max-width: 768px) {
    body {
        -webkit-text-size-adjust: 100%;
        -moz-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }

    .preview-container,
    .upload-container,
    .about-tool,
    .footer {
        width: 100%;
        min-width: 320px;
        overflow-x: hidden;
        box-sizing: border-box;
    }

    img {
        max-width: 100%;
        height: auto;
    }

    input,
    button,
    select,
    textarea {
        max-width: 100%;
    }
}

/* Add minimum touch target sizes */
@media (max-width: 480px) {

    button,
    .nav-links li a,
    .browse-text,
    .format,
    .social-icon {
        min-height: 44px;
        min-width: 44px;
        padding: 12px;
        line-height: 1;
    }
}

/* Background Options Styles */
.background-options {
    display: none;
    margin: 1.5rem 0;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.background-options h4 {
    margin-bottom: 1rem;
    color: var(--text-color);
}

.color-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.color-picker {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.color-picker input[type="color"] {
    width: 50px;
    height: 50px;
    padding: 0;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    background: none;
}

.color-picker label {
    color: var(--text-color);
    font-size: 0.9rem;
}

.preset-colors {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.color-btn {
    width: 40px;
    height: 40px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.color-btn:hover {
    transform: scale(1.1);
}

/* Dark theme adjustments */
[data-theme="dark"] .background-options {
    background: rgba(0, 0, 0, 0.2);
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .color-options {
        gap: 0.8rem;
    }

    .color-btn {
        width: 35px;
        height: 35px;
    }
}

/* Result Wrapper Styles */
.result-wrapper {
    position: relative;
    width: 100%;
    background-color: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    transition: background-color 0.3s ease;
    aspect-ratio: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-wrapper .image-preview {
    display: block;
    max-width: 100%;
    max-height: 400px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.beta-button {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 12px 24px;
    background: linear-gradient(45deg, #FF6B6B, #4ECDC4);
    border: none;
    border-radius: 25px;
    color: white;
    font-weight: bold;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    overflow: hidden;
    z-index: 1;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.beta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.beta-icon {
    margin-right: 8px;
    font-size: 16px;
    display: inline-block;
    transition: transform 0.3s ease;
}

.beta-button:hover .beta-icon {
    transform: translateX(-3px);
}

.beta-shine {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.1) 50%,
            rgba(255, 255, 255, 0) 100%);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }

    100% {
        transform: translateX(100%) rotate(45deg);
    }
}