/* ==UserStyle==
@name           Choose your text size on all websites
@description    Customize the text size on all websites without zooming.
@version        1.0.0
@author         BreatFR (https://breat.fr)
@namespace      https://breat.fr
@homepageURL    https://usercssjs.breat.fr/c/choose-font-size
@updateURL      https://code.breat.fr/c/choose-font-size/css/pc.user.css
@supportURL     https://discord.gg/Q8KSHzdBxs
@license        AGPL-3.0-or-later; https://www.gnu.org/licenses/agpl-3.0.txt
@preprocessor   stylus

@var    range   fontsize    "Choose your text size:"     [1.2, 1, 2, 0.05, "rem"]
==/UserStyle== */

/* ==Credits==
Website         https://breat.fr
Bluesky			https://bsky.app/profile/breatfroff.bsky.social
facebook        https://www.facebook.com/breatfroff
mastodon        https://mastodon.social/@breat_fr
telegram        https://t.me/breatfr
vk              https://vk.com/breatfroff
X (twitter)     https://x.com/breatfroff
==/Credits== */

/* ==Support==
brave Creators  https://publishers.basicattentiontoken.org/c/breatfr
ko-fi           https://ko-fi.com/breatfr
PayPal          https://paypal.me/breat
==/Support== */

@-moz-document url-prefix("ftp://"), url-prefix("http://"), url-prefix("https://") {
/* ========================================================
    Websites
======================================================== */
    :root {
        --fontsize: fontsize;
    }

    a,
    article,
    aside,
    blockquote,
    body,
    button,
    code,
    dd,
    div,
    dl,
    dt,
    figcaption,
    figure,
    footer,
    form,
    h1,
    h2,
    h3,
    h4,
    h5,
    h6,
    hgroup,
    header,
    html,
    input,
    label,
    li,
    main,
    nav,
    ol,
    option,
    p,
    pre,
    section,
    select,
    span,
    table,
    td,
    textarea,
    th,
    ul {
        line-height: 1.5 !important;
    }

    a,
    article,
    aside,
    blockquote,
    body,
    button,
    code,
    dd,
    div,
    dl,
    dt,
    figcaption,
    figure,
    footer,
    form,
    hgroup,
    header,
    html,
    input,
    label,
    li,
    main,
    nav,
    ol,
    option,
    p,
    pre,
    section,
    select,
    span,
    table,
    td,
    textarea,
    th,
    ul {
        font-size: fontsize !important;
    }

    h1 {
        font-size: calc(var(--fontsize) + .3rem) !important;
    }

    h2 {
        font-size: calc(var(--fontsize) + .25rem) !important;
    }

    h3 {
        font-size: calc(var(--fontsize) + .2rem) !important;
    }

    h4 {
        font-size: calc(var(--fontsize) + .15rem) !important;
    }

    h5 {
        font-size: calc(var(--fontsize) + .1rem) !important;
    }

    h6 {
        font-size: calc(var(--fontsize) + .05rem) !important;
    }
}

@-moz-document url-prefix("chrome-extension://") {
/* ========================================================
    Stylus popup
======================================================== */
    :root {
        --fontsize: fontsize;
    }

    #stylus-popup #message-box-title {
        font-size: calc(var(--fontsize) + .2rem) !important;
    }

    #stylus-popup .i-close {
        font-size: calc(var(--fontsize) + .3rem) !important;
    }

    #stylus-popup .config-body {
        font-size: fontsize !important;
        white-space: normal;
    }

    #stylus-popup #message-box-buttons {
        display: flex;
        flex-wrap: wrap;
        row-gap: 1em;
        justify-content: space-between;
    }
    #stylus-popup #message-box-buttons>:nth-child(n+2) {
        margin-left: 0;
    }
    #stylus-popup #message-box-buttons * {
        font-size: fontsize !important;
    }
}
