 /* --- CSS STYLING --- */
        :root {
            --primary-brand: #6366f1;
            --primary-hover: #4f46e5;
            --merge-blue: #2563eb;
            --split-orange: #ea580c;
            --compress-green: #16a34a;
            --convert-purple: #9333ea;
            --jpg-pink: #db2777;
            --unlock-teal: #0d9488;
            --bg-gray: #f8fafc;
            --text-dark: #1e293b;
            --text-gray: #64748b;
            --border-light: #e2e8f0;
        }

        * { box-sizing: border-box; margin: 0; padding: 0; }

        body {
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
            background-color: var(--bg-gray);
            color: var(--text-dark);
            display: flex;
            flex-direction: column;
            min-height: 100vh;
        }

        /* --- HERO --- */
        .hero {
            text-align: center;
            padding: 70px 20px 50px;
            background-color: white;
        }
        .hero h1 { font-size: 46px; font-weight: 700; margin-bottom: 20px; color: var(--text-dark); line-height: 1.2; }
        .hero p { font-size: 18px; color: var(--text-gray); max-width: 600px; margin: 0 auto; }

        /* --- TOOLS GRID --- */
        .tools-section {
            max-width: 1200px;
            margin: 0 auto;
            padding: 20px 40px 80px;
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 20px;
        }

        @media (max-width: 1100px) { .tools-section { grid-template-columns: repeat(3, 1fr); } }
        @media (max-width: 800px) { .tools-section { grid-template-columns: repeat(2, 1fr); } }
        @media (max-width: 500px) { .tools-section { grid-template-columns: 1fr; padding: 20px; } }

        .tool-card {
            background: white;
            border: 1px solid var(--border-light);
            border-radius: 10px;
            padding: 24px;
            text-decoration: none;
            position: relative;
            overflow: hidden;
            display: flex;
            flex-direction: column;
            min-height: 160px;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .tool-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 12px 24px rgba(0,0,0,0.08);
            border-color: transparent;
        }

        .tool-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: #ccc; }
        
        /* Tool Specific Colors */
        .merge::before { background: var(--merge-blue); }
        .split::before { background: var(--split-orange); }
        .compress::before { background: var(--compress-green); }
        .pdf-word::before { background: var(--convert-purple); }
        .pdf-jpg::before { background: var(--jpg-pink); }
        .jpg-pdf::before { background: var(--jpg-pink); }
        .rotate::before { background: var(--unlock-teal); }
        .unlock::before { background: var(--unlock-teal); }
        .watermark::before { background: var(--convert-purple); }
        .page-numbers::before { background: var(--merge-blue); }
        .protect::before { background: var(--split-orange); }
        .sign::before { background: var(--compress-green); }

        .tool-icon { width: 40px; height: 40px; margin-bottom: 15px; display: flex; align-items: center; }
        .tool-title { font-size: 17px; font-weight: 700; margin-bottom: 8px; color: var(--text-dark); }
        .tool-desc { font-size: 13px; color: var(--text-gray); line-height: 1.4; }

        /* --- SEO CONTENT SECTION (Hidden visually, but readable by Google) --- */
        .seo-content {
            background: white;
            padding: 60px 20px;
            text-align: center;
            border-top: 1px solid var(--border-light);
        }
        .seo-content h2 { font-size: 24px; margin-bottom: 15px; color: var(--text-dark); }
        .seo-content p { max-width: 800px; margin: 0 auto 20px; color: var(--text-gray); line-height: 1.6; }


        /* --- MODAL / POPUP --- */
        #work-area {
            display: none;
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background: rgba(15, 23, 42, 0.7);
            z-index: 100;
            justify-content: center; align-items: center;
            backdrop-filter: blur(4px);
        }

        .modal-content {
            background: white; padding: 40px;
            border-radius: 12px;
            width: 90%; max-width: 550px;
            text-align: center;
            position: relative;
            box-shadow: 0 20px 40px rgba(0,0,0,0.2);
            animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        }

        @keyframes popIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }

        .close-btn {
            position: absolute; top: 15px; right: 20px;
            font-size: 28px; cursor: pointer;
            opacity: 0.3; font-weight: 300;
            color: var(--text-dark);
            text-decoration: none;
        }
        .close-btn:hover { opacity: 1; }

        .drop-zone {
            border: 2px dashed var(--border-light);
            padding: 50px 20px; margin: 30px 0 20px;
            border-radius: 8px; background: #fafbff; cursor: pointer;
            transition: all 0.3s;
        }
        .drop-zone:hover, .drop-zone.over { border-color: var(--primary-brand); background: #f0f2ff; }

        .file-list { text-align: left; margin-bottom: 20px; max-height: 150px; overflow-y: auto; }
        .file-item {
            background: #f8fafc; padding: 10px; margin-bottom: 5px;
            border-radius: 6px; font-size: 14px;
            display: flex; justify-content: space-between;
            border: 1px solid #eee;
        }

        .process-btn {
            background: var(--primary-brand);
            color: white; border: none;
            padding: 12px 40px; font-size: 16px;
            border-radius: 6px; cursor: pointer;
            font-weight: 600; transition: background 0.2s;
            width: 100%;
        }
        .process-btn:hover { background: var(--primary-hover); }
        
        #status-msg { margin-top:15px; font-size:14px; }
        
        
        
        /* --- HERO TOOL SECTION --- */
        .tool-hero {
            text-align: center;
            padding: 60px 20px 40px;
            background-color: white;
            border-bottom: 1px solid var(--border-light);
        }

        .tool-header-bar { display: flex; justify-content: center; margin-bottom: 20px; }
        .tool-icon-circle {
            width: 80px; height: 80px;
            border-radius: 50%;
            display: flex; align-items: center; justify-content: center;
            background: #eff6ff; 
            color: #2563eb;
            box-shadow: 0 10px 25px rgba(37, 99, 235, 0.1);
        }

        .tool-hero h1 { font-size: 36px; font-weight: 700; margin-bottom: 10px; color: var(--text-dark); }
        .tool-hero p { font-size: 16px; color: var(--text-gray); max-width: 600px; margin: 0 auto; line-height: 1.6; }

        /* --- WORK AREA --- */
        .work-container {
            max-width: 800px;
            margin: 40px auto;
            padding: 0 20px;
            flex-grow: 1;
        }

        .upload-box {
            background: white;
            border: 2px dashed var(--border-light);
            border-radius: 12px;
            padding: 60px 20px;
            text-align: center;
            cursor: pointer;
            transition: all 0.3s;
            position: relative;
        }

        .upload-box:hover { border-color: var(--primary-brand); background: #fcfcff; }
        
        .upload-icon { margin-bottom: 20px; color: var(--primary-brand); }

        .btn-select-files {
            background: var(--primary-brand);
            color: white; border: none;
            padding: 12px 30px; font-size: 16px;
            border-radius: 6px; cursor: pointer;
            font-weight: 600;
            margin-top: 20px;
        }

        /* --- FILE LIST --- */
        .file-list-container {
            background: white;
            border-radius: 12px;
            padding: 20px;
            margin-top: 20px;
            box-shadow: 0 4px 6px rgba(0,0,0,0.02);
        }
        
        .file-item {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 15px;
            border-bottom: 1px solid #f1f5f9;
        }
        .file-item:last-child { border-bottom: none; }
        .file-info { display: flex; align-items: center; }
        .file-icon { width: 40px; height: 40px; background: #f1f5f9; border-radius: 8px; display: flex; align-items: center; justify-content: center; margin-right: 15px; color: #64748b; }
        .file-name { font-weight: 500; font-size: 15px; color: var(--text-dark); }
        .file-size { font-size: 13px; color: var(--text-gray); }
        .remove-btn { background: none; border: none; color: #ef4444; cursor: pointer; font-size: 14px; font-weight: 500; }

        /* --- ACTION BAR --- */
        .action-bar { margin-top: 30px; text-align: center; }
        .btn-merge {
            color: white;
            border: none;
            padding: 15px 60px;
            font-size: 18px;
            font-weight: 600;
            border-radius: 8px;
            cursor: pointer;
            box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
            transition: transform 0.1s;
        }
        .btn-merge:active { transform: scale(0.98); }
        
        .options-row { margin-top: 20px; margin-bottom: 30px; display: flex; justify-content: center; gap: 20px; color: var(--text-gray); font-size: 14px; }

        /* --- SEO CONTENT SECTION --- */
        .seo-section {
            background: white;
            padding: 60px 20px;
            border-top: 1px solid var(--border-light);
            margin-top: 40px;
        }

        .seo-container {
            max-width: 800px;
            margin: 0 auto;
        }

        .seo-container h2 {
            font-size: 22px;
            margin-bottom: 20px;
            color: var(--text-dark);
            border-left: 4px solid var(--primary-brand);
            padding-left: 15px;
        }

        .seo-container p {
            font-size: 15px;
            line-height: 1.8;
            color: var(--text-gray);
            margin-bottom: 20px;
        }

        /* Tags / Related Links */
        .related-tags {
            margin-top: 40px;
            padding-top: 20px;
            border-top: 1px solid var(--border-light);
        }

        .tag-cloud {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 15px;
        }

        .tag-link {
            text-decoration: none;
            background: #f1f5f9;
            color: var(--text-gray);
            padding: 8px 16px;
            border-radius: 20px;
            font-size: 13px;
            font-weight: 500;
            transition: all 0.2s;
            border: 1px solid transparent;
        }

        .tag-link:hover {
            background: white;
            color: var(--primary-brand);
            border-color: var(--primary-brand);
        }
        
        
        
        
        
        
         /* Footer Variables */
    .site-footer {
        --footer-bg: #0f172a; /* Dark Slate */
        --footer-text: #94a3b8; /* Gray */
        --footer-heading: #e2e8f0;
        --footer-accent: #4f46e5;
        background-color: var(--footer-bg);
        color: var(--footer-text);
        font-family: 'Inter', sans-serif;
        padding: 4rem 1.5rem 2rem;
        margin-top: auto;
        border-top: 1px solid rgba(255,255,255,0.05);
    }

    .footer-container {
        max-width: 1200px;
        margin: 0 auto;
    }

    /* Top Section */
    .footer-grid {
        display: grid;
        grid-template-columns: 1.5fr repeat(3, 1fr);
        gap: 3rem;
        padding-bottom: 3rem;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    /* Brand Section */
    .footer-brand .logo {
        display: inline-flex;
        align-items: center;
        gap: 10px;
        margin-bottom: 1.5rem;
        text-decoration: none;
    }
    .footer-brand .logo-icon {
        width: 36px; height: 36px;
        background: linear-gradient(135deg, var(--footer-accent), #a855f7);
        border-radius: 8px;
        display: flex; align-items: center; justify-content: center;
        color: white; font-weight: bold; font-size: 18px;
    }
    .footer-brand .logo-text {
        font-size: 20px; font-weight: 700; color: white;
    }
    .footer-brand p {
        font-size: 0.95rem;
        line-height: 1.7;
        max-width: 280px;
        margin-bottom: 1.5rem;
    }

    /* Social Icons */
    .social-icons { display: flex; gap: 12px; }
    .social-icon {
        width: 36px; height: 36px;
        border-radius: 8px;
        background: rgba(255,255,255,0.05);
        display: flex; align-items: center; justify-content: center;
        transition: all 0.2s;
    }
    .social-icon:hover {
        background: var(--footer-accent);
        transform: translateY(-2px);
    }
    .social-icon svg { width: 18px; height: 18px; fill: var(--footer-text); transition: fill 0.2s; }
    .social-icon:hover svg { fill: white; }

    /* Links Section */
    .footer-links h4 {
        color: var(--footer-heading);
        font-size: 0.9rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 1.5rem;
    }
    .footer-links ul { list-style: none; }
    .footer-links li { margin-bottom: 0.8rem; }
    .footer-links a {
        color: var(--footer-text);
        text-decoration: none;
        font-size: 0.95rem;
        transition: color 0.2s;
    }
    .footer-links a:hover { color: white; }

    /* Bottom Section */
    .footer-bottom {
        padding-top: 2rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 0.85rem;
        flex-wrap: wrap;
        gap: 1rem;
    }
    .footer-bottom-links a {
        color: var(--footer-text);
        text-decoration: none;
        margin-left: 20px;
        transition: color 0.2s;
    }
    .footer-bottom-links a:hover { color: white; }

    /* Responsive */
    @media (max-width: 768px) {
        .footer-grid {
            grid-template-columns: 1fr 1fr;
            gap: 2rem;
        }
        .footer-brand {
            grid-column: 1 / -1;
            text-align: center;
        }
        .footer-brand p { margin: 0 auto 1.5rem; }
        .social-icons { justify-content: center; }
    }
    @media (max-width: 480px) {
        .footer-grid {
            grid-template-columns: 1fr;
            text-align: center;
        }
        .footer-bottom {
            flex-direction: column;
            text-align: center;
        }
        .footer-bottom-links a { margin: 0 10px; }
    }