/* STEALTH SEO - Hidden from users but visible to search engines */
[style*="display: none"] {
    display: none !important;
}

/* Ensure hidden content doesn't affect layout */
[style*="display: none"] {
    position: absolute;
    left: -9999px;
    top: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

header {
    background: white;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: #2563eb;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    font-size: 2rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-5px);
    }

    60% {
        transform: translateY(-3px);
    }
}

nav {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

nav button {
    background: none;
    border: none;
    color: #475569;
    cursor: pointer;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

nav button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.1), transparent);
    transition: left 0.5s;
}

nav button:hover::before {
    left: 100%;
}

nav button:hover,
nav button.active {
    background: #2563eb;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

nav button.active {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #2563eb;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.mobile-menu-btn:hover {
    background: #eff6ff;
    transform: scale(1.1);
}

/* Mobile Navigation */
.mobile-nav {
    display: block;
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    transition: left 0.3s ease;
    padding: 2rem 1rem;
    overflow-y: auto;
}

.mobile-nav.active {
    left: 0;
    display: block;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.mobile-nav-logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2563eb;
}

.close-menu {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #64748b;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.close-menu:hover {
    background: #ef4444;
    color: white;
}

.mobile-nav-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.mobile-nav-button {
    background: none;
    border: none;
    color: #475569;
    cursor: pointer;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    font-size: 1rem;
    text-align: left;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}


.mobile-nav-button.active {
    background: #eff6ff;
    color: #2563eb;
    border-left-color: #2563eb;
    transform: translateX(5px);
}

/* Overlay for mobile menu */
.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(2px);
}

.mobile-overlay.active {
    display: block;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    nav {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
        order: 1;
        /* First item - left side */
    }

    .logo {
        font-size: 1.5rem;
        order: 2;
        /* Second item - center */
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }

    .logo-icon {
        font-size: 1.7rem;
    }

    .header-content {
        display: flex;
        justify-content: space-between;
        position: relative;
        /* Needed for absolute logo positioning */
    }
}

@media (max-width: 480px) {
    .header-content {
        padding: 0.75rem 0;
    }

    .logo {
        font-size: 1.3rem;
    }

    .mobile-nav {
        width: 100%;
    }
}

/* AdSense placeholder - Top Banner */
.ad-banner {
    background: #e2e8f0;
    border: 2px dashed #cbd5e1;
    padding: 1rem;
    text-align: center;
    margin: 1.5rem auto;
    border-radius: 8px;
    color: #64748b;
    font-size: 0.9rem;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1rem;
    margin: 1rem 0;
    padding: 0 1rem;
    width: 100%;
}

.tool-area {
    padding: 1rem;
    background: transparent;
    width: 100%;
}

.tool-section {
    display: none;
}

.tool-section.active {
    display: block;
}

h2 {
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

.tool-description {
    color: #64748b;
    margin-bottom: 1.5rem;
}

.upload-area {
    text-align: center;
    border: 3px dashed #cbd5e1;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    background: #f8fafc;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 1.5rem;
    max-width: 900px;
    width: 100%;
}

.upload-area:hover {
    border-color: #2563eb;
    background: #eff6ff;
}

.upload-area.dragover {
    border-color: #2563eb;
    background: #dbeafe;
}

.upload-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

input[type="file"] {
    display: none;
}

.file-list {
    margin: 1rem 0;
    max-width: 900px;
}

.file-item,
.single-file-item {
    background: #f1f5f9;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid #10b981;
}

.remove-file {
    background: #ef4444;
    color: white;
    border: none;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
}

.controls {
    max-width: 900px;
    width: 100%;
    margin: 1.5rem 0;
}

.control-group {
    margin-bottom: 1rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    color: #475569;
    font-weight: 500;
}

input[type="number"],
select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
}

.btn {
    max-width: 900px;
    width: 100%;
    background: #2563eb;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
    width: 100%;
}

.btn:hover:not(:disabled) {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

.btn:disabled {
    background: #94a3b8;
    cursor: not-allowed;
}

.btn-secondary {
    background: #10b981;
}

.btn-secondary:hover:not(:disabled) {
    background: #059669;
}

.result-area {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: #f0fdf4;
    border-radius: 8px;
    text-align: center;
    display: none;
}

.result-area.show {
    display: block;
}

.error-area {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: #fef2f2;
    border: 2px solid #fecaca;
    border-radius: 8px;
    color: #991b1b;
    display: none;
}

.error-area.show {
    display: block;
}

.progress {
    margin: 1rem 0;
    text-align: center;
    color: #2563eb;
    font-weight: 500;
}

.warning-box {
    background: #fef3c7;
    border: 2px solid #fde047;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    color: #78350f;
    font-size: 0.9rem;
    display: inline-flex;
    /* This also makes it width-fit to content */
    max-width: 100%;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, .3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* AdSense placeholder - Sidebar */
.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.ad-sidebar {
    background: #e2e8f0;
    border: 2px dashed #cbd5e1;
    padding: 1rem;
    text-align: center;
    border-radius: 8px;
    color: #64748b;
    font-size: 0.9rem;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* AdSense placeholder - Below Result */
.ad-result {
    background: #e2e8f0;
    border: 2px dashed #cbd5e1;
    padding: 1rem;
    text-align: center;
    margin: 1.5rem 0;
    border-radius: 8px;
    color: #64748b;
    font-size: 0.9rem;
}

/* Colorful Service Icons */
.service-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.service-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-icon:hover::before {
    opacity: 1;
}

/* Merge PDF - Blue */
.service-icon.merge {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
}

/* Compress PDF - Green */
.service-icon.compress {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

/* Split PDF - Orange */
.service-icon.split {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

/* Convert PDF - Purple */
.service-icon.convert {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
}

.blog-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.4);
}

/* Single file display styling */
.single-file-list {
    margin: 1rem 0;
    max-width: 900px;
}

.single-file-item {
    background: #f1f5f9;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid #10b981;
}

/* Update blog card styles for better icon integration */
.blog-card {
    background: transparent;
    padding: 1.5rem;
    transition: all 0.3s ease;
    text-align: center;
    border: none;
    position: relative;
    cursor: pointer;
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-card h3 {
    color: #1e293b;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    font-weight: 600;
}

.blog-card p {
    color: #64748b;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* Content Pages */
.content-page {
    display: none;
    background: transparent;
    padding: 1rem;
}

.content-page.active {
    display: block;
}

.content-page h1 {
    color: #1e293b;
    margin-bottom: 1rem;
    font-size: 2rem;
}

.content-page h2 {
    color: #334155;
    margin: 1.5rem 0 0.5rem;
    font-size: 1.5rem;
}

.content-page p {
    margin-bottom: 1rem;
    color: #475569;
}

.content-page ul,
.content-page ol {
    margin: 1rem 0 1rem 2rem;
    color: #475569;
}

.content-page li {
    margin-bottom: 0.5rem;
}

.content-page a {
    color: #2563eb;
    text-decoration: none;
}

.content-page a:hover {
    text-decoration: underline;
}

/* FAQ Section */
.faq-item {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 1.5rem;
}

.faq-question {
    font-weight: bold;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.faq-answer {
    color: #475569;
}

/* Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.blog-card a {
    color: #2563eb;
    font-weight: 500;
    display: inline-block;
    margin-top: 0.5rem;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    color: #64748b;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: #64748b;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: #2563eb;
}

.breadcrumb span {
    margin: 0 0.5rem;
}

footer {
    background: #1e293b;
    color: white;
    padding: 2rem 0;
    margin-top: 4rem;
    text-align: center;
}

.footer-links {
    display: flex;
    gap: 2rem;
    justify-content: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
}

.footer-links a:hover {
    color: white;
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }
}