/* PDF Champ shared chrome: navbar mega-menu + footer + scroll-top */
/* No global * / body resets — safe for home-v7 / download pages */

.navbar, .navbar *, .footer, .footer *, .tools-dropdown, .tools-dropdown *, .scroll-top {
    box-sizing: border-box;
}

/* Keep classic site typography inside chrome (do not inherit page fonts like Manrope) */
.navbar,
.footer {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    letter-spacing: normal;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.navbar button,
.navbar a,
.navbar span,
.navbar li,
.footer a,
.footer p,
.footer h4,
.footer li {
    font-family: inherit;
    letter-spacing: normal;
}

/* Navigation */
.navbar {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 15px 50px;
            background: #fff;
            box-shadow: 0 2px 10px rgba(0,0,0,0.1);
            position: relative;
            z-index: 1000;
        }

        .navbar-logo {
            display: flex;
            align-items: center;
            font-size: 24px;
            font-weight: bold;
            color: #E31E24;
        }

        .navbar-logo img {
            height: 51px;
            width: 190px;
            object-fit: contain;
            margin-right: 10px;
        }

        .navbar-links {
            display: flex;
            list-style: none;
            gap: 30px;
            align-items: center;
            position: relative;
        }

        .navbar-links li {
            position: relative;
        }

        .navbar-links a {
            text-decoration: none;
            color: #333;
            font-weight: 600;
            font-size: 14px;
            text-transform: uppercase;
            transition: color 0.3s;
            display: flex;
            align-items: center;
            gap: 5px;
            cursor: pointer;
        }

        .navbar-links a:hover {
            color: #E31E24;
        }

        .dropdown-arrow {
            font-size: 10px;
            transition: transform 0.3s;
        }

        .btn-all-tools.active .dropdown-arrow {
            transform: rotate(180deg);
        }

        /* Dropdown Menu - Tabbed Mega Menu */
        .tools-dropdown {
            position: absolute;
            top: 100%;
            right: 0;
            background: #fff;
            border-radius: 12px;
            box-shadow: 0 10px 40px rgba(0,0,0,0.15);
            margin-top: 15px;
            display: none;
            flex-direction: column;
            width: 720px;
            max-width: 96vw;
            max-height: 75vh;
            min-height: 320px;
            z-index: 1001;
            animation: fadeInDown 0.3s ease;
            overflow: hidden;
        }

        @keyframes fadeInDown {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .btn-all-tools.active .tools-dropdown {
            display: flex;
        }

        .mega-menu-tabs {
            display: flex;
            flex-wrap: wrap;
            gap: 4px;
            padding: 12px 12px 0;
            border-bottom: 1px solid #e5e5e5;
            background: #fafafa;
            flex-shrink: 0;
            overflow-x: auto;
            -webkit-overflow-scrolling: touch;
        }

        .mega-menu-tab {
            padding: 10px 14px;
            border: none;
            background: transparent;
            font-size: 12px;
            font-weight: 600;
            color: #666;
            cursor: pointer;
            border-radius: 6px;
            white-space: nowrap;
            transition: color 0.2s, background 0.2s;
            border-bottom: 2px solid transparent;
            margin-bottom: -1px;
        }

        .mega-menu-tab:hover {
            color: #E31E24;
            background: #fff;
        }

        .mega-menu-tab.active {
            color: #E31E24;
            background: #fff;
            border-bottom-color: #E31E24;
        }

        .mega-menu-content {
            flex: 1;
            overflow-y: auto;
            padding: 20px 24px 24px;
            min-height: 0;
        }

        .dropdown-tab-panel {
            display: none;
            flex-direction: column;
            flex: 1;
            min-height: 0;
            overflow: hidden;
        }

        .dropdown-tab-panel.active {
            display: flex;
        }

        .online-featured-link {
            flex-shrink: 0;
            margin-bottom: 10px;
            padding-bottom: 10px;
            border-bottom: 1px solid #e5e5e5;
        }

        .online-featured-link a {
            display: inline-flex;
            align-items: center;
            font-size: 14px;
            font-weight: 700;
            color: #E31E24;
            text-decoration: none;
            transition: opacity 0.2s;
        }

        .online-featured-link a:hover {
            opacity: 0.85;
            text-decoration: underline;
        }

        .pdfchamp-subtabs,
        .online-subtabs {
            display: flex;
            flex-wrap: wrap;
            gap: 6px 8px;
            padding: 10px 0 12px;
            border-bottom: 1px solid #e5e5e5;
            background: #fafafa;
            flex-shrink: 0;
        }

        .pdfchamp-subtab,
        .online-subtab {
            padding: 8px 12px;
            font-size: 12px;
            font-weight: 600;
            color: #555;
            background: #fff;
            border: 1px solid #e0e0e0;
            border-radius: 6px;
            cursor: pointer;
            transition: color 0.2s, background 0.2s, border-color 0.2s;
            white-space: nowrap;
        }

        .pdfchamp-subtab:hover,
        .online-subtab:hover {
            color: #E31E24;
            border-color: #E31E24;
        }

        .pdfchamp-subtab.active,
        .online-subtab.active {
            color: #fff;
            background: #E31E24;
            border-color: #E31E24;
        }

        .pdfchamp-subpanels,
        .online-subpanels {
            flex: 1;
            min-height: 0;
            overflow: hidden;
            padding-top: 12px;
        }

        .pdfchamp-subpanel,
        .online-subpanel {
            display: none;
        }

        .pdfchamp-subpanel.active,
        .online-subpanel.active {
            display: block;
        }

        .pdfchamp-subpanel .dropdown-tool-list,
        .online-subpanel .dropdown-tool-list,
        .dropdown-tab-panel[data-tab="alltopdf"] .dropdown-tool-list {
            display: block;
            column-count: 2;
            column-gap: 20px;
        }

        .pdfchamp-subpanel .dropdown-tool-item,
        .online-subpanel .dropdown-tool-item,
        .dropdown-tab-panel[data-tab="alltopdf"] .dropdown-tool-item {
            break-inside: avoid;
        }

        .dropdown-category {
            display: none;
            flex-direction: column;
        }

        .dropdown-category.active {
            display: flex;
        }

        .dropdown-category-title {
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            color: #1a1a1a;
            margin-bottom: 20px;
            letter-spacing: 0.8px;
            padding-bottom: 10px;
            border-bottom: 1px solid #e5e5e5;
        }

        .dropdown-tool-list {
            list-style: none;
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .dropdown-tool-item {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 10px 8px;
            cursor: pointer;
            transition: all 0.2s;
            border-radius: 6px;
            text-decoration: none;
        }

        .dropdown-tool-item a {
            display: flex;
            align-items: center;
            gap: 12px;
            width: 100%;
            text-decoration: none;
            color: inherit;
        }

        .dropdown-tool-item:hover {
            background: #f8f9fa;
            transform: translateX(3px);
        }

        .dropdown-tool-icon {
            width: 36px;
            height: 36px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 22px;
            flex-shrink: 0;
            background: #f8f9fa;
            border-radius: 6px;
            transition: all 0.2s;
        }

        .dropdown-tool-item:hover .dropdown-tool-icon {
            background: #E31E24;
            transform: scale(1.1);
        }

        .dropdown-tool-name {
            font-size: 14px;
            color: #333;
            font-weight: 500;
            transition: color 0.2s;
        }

        .dropdown-tool-item:hover .dropdown-tool-name {
            color: #E31E24;
            font-weight: 600;
        }

        .navbar-actions {
            display: flex;
            gap: 12px;
            align-items: center;
        }

        .btn-login {
            background: transparent;
            border: none;
            color: #333;
            font-weight: 600;
            cursor: pointer;
            padding: 8px 20px;
        }

        .btn-nav-buy {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 9px 18px;
            border-radius: 5px;
            border: 1.5px solid #ddd;
            background: #fff;
            color: #333;
            font-weight: 700;
            font-size: 14px;
            text-decoration: none;
            transition: border-color 0.2s, color 0.2s;
        }

        .btn-nav-buy:hover {
            border-color: #E31E24;
            color: #E31E24;
        }

        .btn-nav-download {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 9px 18px;
            border-radius: 5px;
            border: none;
            background: #E31E24;
            color: #fff;
            font-weight: 700;
            font-size: 14px;
            text-decoration: none;
            transition: background 0.2s;
        }

        .btn-nav-download:hover {
            background: #C41E24;
            color: #fff;
        }

        .btn-all-tools {
            background: #E31E24;
            color: #fff;
            border: none;
            padding: 10px 25px;
            border-radius: 5px;
            font-weight: 600;
            font-size: 14px;
            text-transform: uppercase;
            cursor: pointer;
            transition: background 0.3s;
            display: flex;
            align-items: center;
            gap: 5px;
            position: relative;
        }

        .btn-all-tools:hover {
            background: #C41E24;
        }

        .btn-all-tools.active {
            background: #C41E24;
        }

/* Footer */
.footer {
            background: #2c2c2c;
            color: #fff;
            padding: 60px 20px 30px;
        }

        .footer-content {
            max-width: 1400px;
            margin: 0 auto;
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 40px;
            margin-bottom: 40px;
        }

        .footer-column h4 {
            font-size: 16px;
            font-weight: 600;
            margin-bottom: 20px;
            text-transform: uppercase;
        }

        .footer-column ul {
            list-style: none;
        }

        .footer-column ul li {
            margin-bottom: 12px;
        }

        .footer-column a {
            color: #ccc;
            text-decoration: none;
            font-size: 14px;
            transition: color 0.3s;
        }

        .footer-column a:hover {
            color: #fff;
        }

        .footer-bottom {
            max-width: 1400px;
            margin: 0 auto;
            padding-top: 30px;
            border-top: 1px solid #444;
            text-align: center;
        }

        .footer-bottom p {
            color: #999;
            font-size: 14px;
        }

        /* Scroll to top */
        .scroll-top {
            position: fixed;
            bottom: 30px;
            right: 30px;
            width: 50px;
            height: 50px;
            background: #E31E24;
            color: #fff;
            border: none;
            border-radius: 50%;
            cursor: pointer;
            display: none;
            align-items: center;
            justify-content: center;
            font-size: 20px;
            z-index: 999;
            transition: all 0.3s;
        }

        .scroll-top:hover {
            background: #C41E24;
            transform: translateY(-3px);
        }

        .scroll-top.show {
            display: flex;
            bottom: 150px; /* Moved higher from default 30px */
        }

/* Responsive (chrome only) */
@media (max-width: 1200px) {
            .navbar {
                padding: 15px 25px;
            }
            .tools-dropdown {
                min-width: 0;
                width: 480px;
                max-width: calc(100vw - 40px);
            }
        }

@media (max-width: 968px) {
            .navbar {
                padding: 12px 15px;
                flex-wrap: wrap;
            }
            .navbar-logo img {
                max-height: 44px;
                width: auto;
                max-width: 150px;
            }
            .navbar-links {
                display: none;
            }
            .navbar-actions {
                flex-shrink: 0;
                gap: 8px;
            }
            .btn-nav-buy,
            .btn-nav-download {
                padding: 8px 12px;
                font-size: 12px;
            }
            .btn-all-tools {
                padding: 8px 16px;
                font-size: 13px;
            }
            /* Mega menu: full-width overlay below navbar on tablet/mobile */
            .tools-dropdown {
                position: fixed;
                left: 0;
                right: 0;
                top: 68px;
                width: 100%;
                min-width: 0;
                max-width: none;
                margin-top: 0;
                border-radius: 0;
                box-shadow: 0 8px 24px rgba(0,0,0,0.12);
                max-height: calc(100vh - 68px);
                -webkit-overflow-scrolling: touch;
            }
            .mega-menu-tabs {
                padding: 10px 10px 0;
            }
            .mega-menu-tab {
                padding: 8px 12px;
                font-size: 11px;
            }
            .mega-menu-content {
                padding: 16px 12px 20px;
            }
            .dropdown-category-title {
                font-size: 10px;
                margin-bottom: 12px;
                padding-bottom: 8px;
            }
            .dropdown-tool-item {
                padding: 8px 6px;
            }
            .dropdown-tool-icon {
                width: 32px;
                height: 32px;
                font-size: 18px;
            }
            .dropdown-tool-name {
                font-size: 13px;
            }
        }

@media (max-width: 640px) {
            .navbar {
                padding: 10px 12px;
            }
            .navbar-logo img {
                max-height: 40px;
                max-width: 130px;
            }
            .btn-all-tools {
                padding: 8px 12px;
                font-size: 12px;
            }
            .btn-all-tools .dropdown-arrow {
                font-size: 8px;
            }
            .tools-dropdown {
                top: 60px;
                max-height: calc(100vh - 60px);
            }
            .mega-menu-tabs {
                padding: 8px 8px 0;
            }
            .mega-menu-tab {
                padding: 8px 10px;
                font-size: 10px;
            }
            .mega-menu-content {
                padding: 12px 10px 16px;
            }
            .dropdown-category-title {
                margin-bottom: 10px;
                font-size: 10px;
            }
            .dropdown-tool-item {
                padding: 10px 8px;
            }
            .dropdown-tool-icon {
                width: 36px;
                height: 36px;
                font-size: 20px;
            }
            .dropdown-tool-name {
                font-size: 14px;
            }
            .pdfchamp-subpanel .dropdown-tool-list,
            .online-subpanel .dropdown-tool-list,
            .dropdown-tab-panel[data-tab="alltopdf"] .dropdown-tool-list {
                column-count: 1;
            }
            .pdfchamp-subtabs,
            .online-subtabs {
                display: grid;
                grid-template-columns: 1fr 1fr;
                gap: 8px;
                padding: 10px 0 12px;
            }
            .pdfchamp-subtab,
            .online-subtab {
                padding: 10px 8px;
                font-size: 11px;
                text-align: center;
                min-height: 44px;
                display: flex;
                align-items: center;
                justify-content: center;
            }
        }

@media (max-width: 480px) {
            .navbar {
                padding: 8px 10px;
            }
            .navbar-logo img {
                max-height: 36px;
                max-width: 110px;
            }
            .btn-all-tools {
                padding: 6px 10px;
                font-size: 11px;
            }
            .tools-dropdown {
                top: 52px;
                max-height: calc(100vh - 52px);
            }
            .mega-menu-content {
                padding: 10px 8px 12px;
            }
        }
