/* styles.css */
:root {
    --bg-color: #000;
    --text-color: #fff;
    --border-color: #000;
    --shadow: 0px 3px 0px 0px rgba(0,0,0,0.2);
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    color: var(--text-color);
    text-align: center;
    background-color: var(--bg-color);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow-anchor: none;
}

.page-container {
    background-color: var(--bg-color);
    min-height: 100vh;
}

h1 {
    background: var(--bg-color);
    color: var(--text-color);
    padding: 0;
    margin: 0 auto;
    font-size: 2rem;
    text-transform: uppercase;
    max-width: 728px;
    width: 100%;
    text-align: center;
    font-weight: 400;
    box-shadow: var(--shadow);
}

h3 {
    color: var(--text-color);
    text-decoration: none;
    margin-bottom: 4px;
    background: var(--bg-color);
    font-weight: 600;
    text-transform: uppercase;
}

header {
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 30px;
    line-height: 38px;
    text-transform: uppercase;
    box-shadow: 0px 5px 10px 0px rgba(0,0,0,0.3);
    border-bottom: 1px solid var(--bg-color);
    z-index: 10;
}

nav {
    order: 2;
    margin-right: 10px;
    height: 30px;
    margin-top: -8px;
}

nav ul {
    list-style-type: none;
    display: flex;
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    padding: 0;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    text-decoration: none;
    color: var(--text-color);
    padding: 10px;
}

nav ul li a:hover {
    color: var(--bg-color);
    background: var(--text-color);
    transition: all 0.2s ease-in;
}

.menu-toggle {
    display: none;
    cursor: pointer;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 24px;
    order: 3;
    margin-right: 15px;
}

.menu-toggle:focus {
    outline: 0px solid var(--text-color);
}

.bar {
    background-color: var(--text-color);
    height: 3px;
    width: 100%;
    transition: transform 0.4s, opacity 0.4s;
}

.menu-toggle.active .bar:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active .bar:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.logo {
    display: flex;
    align-items: center;
    font-size: 2em;
    font-weight: 600;
    line-height: 1.8rem;
    margin-left: 10px;
    margin-top: -1px;
}

.logo img {
    max-height: 30px;
    margin-right: 8px;
}

.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--bg-color);
    color: var(--text-color);
    text-align: center;
    padding: 10px 0;
    min-height: 30px;
    z-index: 10;
    border-top: 1px solid var(--bg-color);
}

.footertxt {
    padding: 0 15px;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    line-height: 20px;
    font-weight: 600;
    text-align: right;
    margin-top: 4px;
}

.spacert {
    height: 10px;
}

.spacerb {
    height: 60px;
}

.content-container {
    margin: 41px 0 0 0;
    padding: 10px 20px 20px 20px;
    background: #495057;
    background-attachment: fixed;
    min-height: calc(100vh - 81px);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: none;
    overflow-anchor: none;
}

.content-container.loaded {
    transition: opacity 0.3s ease;
}

#posts-container {
    min-height: 200px;
    width: 100%;
    max-width: 728px;
    margin: 0 auto;
    transition: none;
    overflow-anchor: none;
}

#posts-container.loaded {
    transition: opacity 0.3s ease;
}

.headliner {
    background: var(--bg-color);
    color: var(--text-color);
    padding: 10px;
    margin: 0 auto 5px auto;
    font-size: 1rem;
    max-width: 728px;
    width: 100%;
    text-align: left;
    font-weight: 500;
    text-transform: uppercase;
    box-sizing: border-box;
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: center;
    min-height: 42px;
    box-shadow: var(--shadow);
}

.sidethumb {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.sidethumb picture,
.sidethumb img {
    width: 12px;
    height: 12px;
    border: 0;
    padding-right: 0px;
    padding-top: 0;
    aspect-ratio: 1 / 1;
    display: block;
}

.headtext {
    flex-grow: 1;
    text-align: left;
    margin-top: -2px;
    font-size: 17px;
    font-weight: 500;
    padding: 0 10px;
	margin-left:-5px;
}

.dat {
    font-size: 0.8rem;
    padding-top: 0;
    margin-top: -3px;
    flex-shrink: 0;
    text-align: right;
}

.imglogo {
    margin: 0 auto;
    width: 728px;
    max-width: 100%;
    min-height: 405px;
    background-color: var(--bg-color);
    box-sizing: border-box;
    padding: 10px;
    margin-bottom: 5px;
}

.imglogo img {
    width: 728px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
    border: none;
    box-sizing: border-box;
}

.text {
    visibility: hidden;
    max-height: 0;
    overflow: hidden;
    background: var(--bg-color);
    color: var(--text-color);
    padding: 0 15px;
    margin: 0 auto;
    width: 100%;
    max-width: 728px;
    box-sizing: border-box;
    font-size: 16px;
    font-weight: 350;
    text-align: justify;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s ease, max-height 0.5s ease, padding 0.5s ease;
    margin-bottom: 10px;
}

.text.active {
    visibility: visible;
    max-height: none;
    padding: 15px;
    opacity: 1;
    transform: translateY(0);
    animation: fadeIn 0.5s ease forwards;
    margin-bottom: 5px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(0px); }
    to { opacity: 1; transform: translateY(0); }
}

.text a {
    color: var(--text-color);
    text-decoration: underline;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

.pagination {
    display: none;
    margin: 10px auto 0;
    text-align: center;
    max-width: 728px;
    width: 100%;
    padding-bottom: 15px;
}

.pagination.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.pagination button {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    padding: 8px 16px;
    margin: 0 5px;
    cursor: pointer;
    font-size: 0.9rem;
    text-transform: uppercase;
    transition: background 0.2s ease, color 0.2s ease;
}

.pagination button:hover:not(:disabled),
.pagination button:focus:not(:disabled) {
    background: var(--text-color);
    color: var(--bg-color);
    outline: none;
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination span {
    margin: 0 10px;
    font-size: 0.9rem;
    color: var(--text-color);
}

#percent {
    background: var(--bg-color);
    padding: 2px 6px;
    border: 0px solid var(--border-color);
    font-size: 1em;
    font-weight: 600;
    border-radius: 4px;
    display: inline-block;
    line-height: 1.2;
    color: white;
    background: -webkit-linear-gradient(#eee, #333);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#percent.show {
    opacity: 1;
    visibility: visible;
}

.toggle-image {
    cursor: pointer;
    width: 728px;
    max-width: 100%;
    height: auto;
    aspect-ratio: 728 / 405;
    object-fit: contain;
    display: block;
    margin-bottom: 5px;
}

.toggle-image:focus {
    outline: 0px solid var(--text-color);
}

.scroll-buttons {
    position: fixed;
    bottom: 70px;
    right: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 5;
}

.scroll-btn {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--bg-color), #333);
    border: 1px solid var(--border-color);
    border-radius: 0%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-color);
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
    opacity: 0;
    visibility: hidden;
    box-shadow: var(--shadow);
}

.scroll-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-btn:hover,
.scroll-btn:focus {
    background: #ef233c;
    transform: scale(1.1);
    outline: none;
}

.scroll-to-top {
    transform: translateY(10px);
}

.scroll-to-bottom {
    transform: translateY(-10px);
}

.noscript-warning {
    background: #ff4d4d;
    color: #fff;
    padding: 10px;
    text-align: center;
    font-size: 0.9rem;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background-color: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
}

@media only screen and (max-width: 768px) {
    body {
        background-color: var(--bg-color);
        overflow-anchor: none;
    }

    .content-container {
        margin: 41px 0 0 0;
        padding: 8px 10px 10px 10px;
        background: #495057;
        min-height: calc(100vh - 81px);
        box-sizing: border-box;
        align-items: center;
        transition: none;
        overflow-anchor: none;
    }

    .content-container.loaded {
        transition: opacity 0.3s ease;
    }

    h1 {
        font-size: clamp(1.5rem, 4vw, 2rem);
        max-width: 100%;
        width: 100%;
    }

    #posts-container {
        min-height: 150px;
        max-width: 100%;
        margin: 0 auto;
        transition: none;
        overflow-anchor: none;
    }

    #posts-container.loaded {
        transition: opacity 0.3s ease;
    }

    .headliner {
        font-size: 0.8rem;
        max-width: 100%;
        width: 100%;
        padding: 8px;
        margin: 0 auto 3px auto;
        min-height: 40px;
        box-shadow: none;
        display: flex;
        flex-wrap: nowrap;
        justify-content: space-between;
        align-items: center;
    }

    .sidethumb {
        display: none;
    }

    .sidethumb picture,
    .sidethumb img {
        width: 12px;
        height: 12px;
        border: 0;
        padding-right: 5px;
        padding-top: 0;
        aspect-ratio: 1 / 1;
    }

    .headtext {
        font-size: 0.9rem;
        padding: 0 8px;
        flex-grow: 1;
        text-align: left;
		margin-top:0px;
    }

    .dat {
        font-size: 0.8rem;
        padding: 0;
        margin-top: -2px;
        text-align: right;
    }

    .imglogo {
        width: 100%;
        max-width: 100%;
        min-height: auto;
        padding: 10px;
        background-color: var(--bg-color);
        box-sizing: border-box;
    }

    .imglogo img {
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 728 / 405;
        object-fit: contain;
        display: block;
        margin: 0 auto;
        border: none;
        box-sizing: border-box;
    }

    .toggle-image {
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 728 / 405;
        object-fit: contain;
        margin-bottom: 2px;
    }

    .text {
        font-size: 0.9rem;
        max-width: 100%;
        width: 100%;
        padding: 0 8px;
        margin: 0 auto;
    }

    .text.active {
        padding: 0 20px 0 20px;
        max-height: 2000px;
        margin-bottom: 2px;
    }

    .pagination {
        max-width: 100%;
        width: 100%;
        margin: 5px auto 0;
        padding-bottom: 10px;
    }

    .pagination button {
        font-size: 0.8rem;
        padding: 6px 12px;
    }

    .pagination span {
        font-size: 0.8rem;
    }

    .logo {
        font-size: 1.2rem;
        line-height: 48px;
        margin-top: 0px;
    }

    #percent {
        margin-top: 0px;
    }

    .logo img {
        max-height: 28px;
    }

    .footer {
        min-height: 30px;
        padding: 8px 0;
    }

    .footertxt {
        padding: 0 10px;
        font-size: 0.8rem;
        text-align: center;
    }

    nav ul {
        display: none;
        flex-direction: column;
        background-color: var(--bg-color);
        position: absolute;
        top: 48px;
        left: 0;
        width: 100%;
        z-index: 12;
        padding: 10px 0;
        box-shadow: 0 2px 5px rgba(0,0,0,0.3);
        text-align: center;
    }

    nav ul.active {
        display: flex;
    }

    nav ul li {
        margin: 8px 0;
    }

    nav ul li a {
        padding: 6px;
        font-size: 0.9rem;
    }

    .menu-toggle {
        display: flex;
        margin-right: 10px;
    }

    .scroll-buttons {
        bottom: 60px;
        right: 8px;
    }

    .scroll-btn {
        width: 40px;
        height: 40px;
    }

    .scroll-btn svg {
        width: 18px;
        height: 18px;
    }
}