FitGirl Repacks - Full Width Fix

Unsets max-width and margins for header and page div to make the site full-width.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         FitGirl Repacks - Full Width Fix
// @namespace    http://tampermonkey.net/
// @version      1.1
// @description  Unsets max-width and margins for header and page div to make the site full-width.
// @author       YoȻaptain Jøhn “Søap” MacTavishu
// @match        https://fitgirl-repacks.site/*
// @exclude      https://fitgirl-repacks.site/hypervisor-guide/
// @exclude      https://fitgirl-repacks.site/popular-repacks/
// @grant        none
// @license      CC-BY-NC-SA-4.0
// @run-at       document-start
// ==/UserScript==
(
    function()
    {
        'use strict';

        // Function to inject CSS into the document head
        function addGlobalStyle(css)
        {
            var head, style;
            head = document.getElementsByTagName('head')[0];
            if (!head)
            {
                return;
            }
            style = document.createElement('style');
            style.type = 'text/css';
            style.innerHTML = css;
            head.appendChild(style);
        }

        // Define all CSS rules
        var cssChanges = `
            /* 1. Unset Max-width for header and main page container */
            header, #page.hfeed.site
            {
                max-width: none !important;
                width: 100% !important;
            }

            /* 2. Unset margins on specific media queries for the page container */
            @media screen and (min-width: 1080px)
            {
                #page.hfeed.site
                {
                    margin-left: 0 !important;
                }
            }

            @media screen and (min-width: 1008px)
            {
                #page.hfeed.site
                {
                    margin-right: 0 !important;
                }
            }

            /* 3. Specific width and max-width for content elements */
            .site-content .entry-header,
            .site-content .entry-content,
            .site-content .entry-summary,
            .site-content .entry-meta,
            .page-content
            {
                width: 1330px !important;
                max-width: 9000px !important;
            }

            /* 4. Sidebar positioning and sizing */
            #content-sidebar
            {
                margin-left: -56% !important;
                width: 15% !important;
            }

            /* 5. Flexbox display for navigation links */
            .nav-links
            {
                display: flex !important;
            }

            /* 6. Post Navigation styling (Global reset + specific width/margin) */
            .navigation.post-navigation
            {
                margin: 0 !important;
                margin-left: 230px !important;
                width: 100% !important;
            }
        `;

        // Execute the function
        addGlobalStyle(cssChanges);

    }
)
();