:root {
    --mobile-forum-header-min-size: 60px;
    --mobile-forum-header-links-anchor-padding: .75rem;
    --mobile-forum-header-links-items-gap: .75rem;
}

@media (max-width: 980px) {
    body {
        padding: 0;
    }

    .animated-bg {
        display: none !important;
    }

    .site-wrapper {
        border-radius: 0;
        box-shadow: none;
        padding: 1rem;
        padding-top: var(--mobile-forum-header-min-size);
    }

    .forum-header {
        background-color: white;
        position: fixed;
        top: 0;
        left: 0;
        z-index: 999;
        padding-block: calc(1rem - var(--mobile-forum-header-links-anchor-padding));
        padding-inline: 1rem;
        box-shadow: 0px 0px 10px 0px rgba(0,0,0,.08);
        min-height: var(--mobile-forum-header-min-size);
        width: 100%;
    } 

    .logo-symbol {
        width: 32px;
        height: 32px;
        font-size: 18px;
    }

     .logo-text {
        font-size: 18px;
    }

    .header-links > li > a > span {
        display: none;
    }

    .header-links > li > a {
        padding: var(--mobile-forum-header-links-anchor-padding);
    }

    .header-links > li > a:before,
    .header-links > li > a:after,
    .header-links > li:after,
    .header-photo:before {
        content: none !important;
        display: none !important;
    }

    .mobile-dropdown-header-icon {
        display: inline-block;
    }

    .desktop-dropdown-header-icon {
        display: none;
    }

    .header-links {
        gap: var(--mobile-forum-header-links-items-gap);
    }

    #username_logged_in {
        margin-left: calc(var(--mobile-forum-header-links-anchor-padding) / 2);
    }

    .breadcrumbs-list {
        overflow-x: auto;
        white-space: nowrap;
    }

    .actionbar {
        flex-wrap: wrap;
    }

    .phpbb-ads img {
        max-width: 100%;
    }

    .cp-wrap {
        flex-direction: column;
    }

    .cp-wrap .cp-menu {
        flex: auto !important;
        flex-basis: auto !important;
        display: block !important;
        visibility: visible !important;
        pointer-events: all !important;
    }

    .cp-main button[data-target-id="cp-menu"] {
        display: none;
    }
}

@media (max-width: 700px) {
    :root {
        --mobile-forum-header-links-items-gap: .5rem;
    }

    h1 {
        font-size: 20px;
    }

    h2 {
        font-size: 18px;
    }

    h3 {
        font-size: 16px;
    }

    h4 {
        font-size: 14px;
    }

    h5 {
        font-size: 14px;
    }

    h6 {
        font-size: 14px;
    }

    p {
        margin-bottom: .5rem;
    }

    .forum-statistics {
        flex-direction: column;
        gap: .5rem;
    }

    .forum-statistics .statistic {
        padding: .5rem;
        gap: .5rem;
    }

    .forum-statistics .statistic svg {
        width: 1.75rem;
        height: 1.75rem;
        margin-bottom: .5rem;
    }

    .forum-statistics .statistic:not(.statistic strong) {
        font-size: 14px;
    }

    .forum-statistics .statistic strong {
        font-size: 16px;
        margin-top: .25rem;
    }

    .cat-title, [class^="column"] h3, .solo, .posting-title, .forum-title, .titlespace, .stat-block > h3 {
        font-size: 16px;
        margin-bottom: .5rem;
    }

    .collapsible-header {
        margin-bottom: .5rem;
    }

    .forumtitle {
        font-size: 14px;
    }

    .site-year h4 {
        font-size: 18px;
    }

    .forum-footer {
        position: static;
        padding: 1rem;
        flex-direction: column;
        align-items: start;
        gap: 0;
    }

    .forum-header {
        gap: var(--mobile-forum-header-links-items-gap);
    }

    .logo-header {
        margin-right: auto;
    }

    .forum-header {
        padding-inline: 10px;
    }

    .mobile-menu .header-links li[data-mobile-menu-item] {
        display: none !important;
    }

    .menu-overlay.open {
        display: block;
    }

    .header-links[data-desktop-menu] {
        display: none !important;
    }

    .header-links[data-mobile-menu] {
        display: flex !important;
    }

    .actionbar-mark {
        display: none;
    }

    .toTop {
        width: 30px;
        height: 30px;
    }

    .toTop svg {
        width: 20px;
        height: 20px;
    }

    .breadcrumbs-header .search-toggle {
        display: none;
    }

    .stat-block:not(:last-child), .stat-block p {
        margin-bottom: 1rem;
    }

    .forum-time-main {
        display: none;
    }

    .site-year, .site-link {
        padding: 0;
    }

    .site-desc {
        gap: 0;
    }

    .site-desc p, .site-year p {
        margin-bottom: 0;
    }

    .panel {
        padding: .5rem;
    }

    .inner-article {
        flex-direction: column;
    }

    .inner-article .postprofile {
        flex: 0;
        border: 0;
        border-bottom: 2px solid #f5f5f5;
        padding: 0;
        padding-block: .5rem;
    }

    .inner-article > .postbody {
        padding: 0;
    }

    .postbody .content {
        margin-top: 1rem;
    }

    li[data-post-btn-mobile-only] {
        display: flex;
    }

    li[data-post-btn-desktop-only] {
        display: none;
    }

    .copy-btn span {
        display: inline-block;
    }

    .dropdown-contents-postbtns li:not([data-post-btn-mobile-only]):not([data-post-btn-thanks]):first-child {
        border: 0;
    }

    .panel-container h2, .panel-container h3 {
        font-size: 16px;
    }

    .post.pm .postbody .post-buttons {
        position: static;
        margin-left: auto;
        margin-bottom: 1rem;
        overflow: auto;
    }

    .post.pm .back2top {
        display: none;
    }

    .panel fieldset.submit-buttons {
        margin: 0;
        font-size: 0;
    }

    fieldset.submit-buttons > * {
        width: 100%;
    }

    fieldset.submit-buttons > *:not(:last-child) {
        margin-bottom: .5rem;
    }

    .subforums-container {
        flex-direction: column;
        gap: 0;
    }

    .form-buttons, .quickreply-btns {
        flex-direction: column;
    }

    .form-buttons > *, .quickreply-btns > * {
        width: 100%;
    }

    .list-inner-pmviewfolder {
        display: none !important;
    }

    .pm.arcticle-pm, .pm-history-panel .post {
        padding: .5rem;
    }

    .pm.arcticle-pm {
        padding-top: 0;
    }
}

@media (max-width: 500px) {
    li[data-mobile-menu-item] .badge {
        position: absolute;
        top: 0;
        right: 0;
    }

    textarea.inputbox, input.inputbox {
        font-size: 16px;
    }
}