Bitcointalk Mobile

Improves readability on bitcointalk.org for mobile

// ==UserScript==
// @name         Bitcointalk Mobile
// @namespace    https://bitcointalk.org
// @version      1.0
// @description  Improves readability on bitcointalk.org for mobile
// @author       Royal Cap
// @match        https://bitcointalk.org/*
// @grant        GM_addStyle
// @run-at 	 document-start
// @license MIT
// ==/UserScript==

(function () {
    'use strict';

    GM_addStyle(`
        html, body {
            width: 100% !important;
            max-width: 100vw !important;
            overflow-x: hidden !important;
            margin: 0 !important;
            padding: 5px !important;
        }

        @media screen and (max-width: 768px) {
            head {
                display: contents;
            }
            head::before {
                content: '<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">';
            }
        }

        body, p, td, tr, div, span, a {
            font-size: 105% !important;
            line-height: 1.4 !important;
        }

        a:link, a:visited {
            text-decoration: underline !important;
        }

        a:hover {
            text-decoration: none !important;
        }


        .post h4, .post h5 {
            font-size: 22px !important;
            font-weight: bold !important;
        }

        .smalltext, .quote, .code  {
            font-size: 20px !important;
        }

        .quote, .code {
            border: 1px solid #ccc !important;
            padding: 10px !important;
        }

        table {
            width: 100% !important;
            max-width: 100% !important;
            box-sizing: border-box !important;
        }

        td {
            word-wrap: break-word !important;
            max-width: 100% !important;
        }

        img {
            max-width: 100% !important;
            height: auto !important;
        }

        .nav, #header, #footer {
            font-size: 18px !important;
            width: 100% !important;
        }

        input, textarea, select {
            border: 1px solid #aaa !important;
            padding-right: 30px !important;
        }

        textarea {
            font-size: 100%;
            font-family: verdana, sans-serif;
            width: 70% !important;
        }

        element.style {
            width: 10ex;
        }

        .titlebg, tr.titlebg th, tr.titlebg td, .titlebg2, tr.titlebg2 th, tr.titlebg2 td {
            font-style: normal;
            border-bottom: none;
            border-top: none;
            padding-left: 0;
            padding-right: 0;
        }
    span.prevnext a:link {
        font-size: 400% !important;
    }
    `);
})();