﻿/* Container for both buttons */
.topic-navigation {
    display: flex;
    justify-content: space-between; 
    width: 100%;
}

/* Base button styles (shared between themes) */
.prev-topic-btn,
.next-topic-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 8px 16px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s, transform 0.1s;
    min-width: 140px;
    background-color: var(--background-brand-weak);
    color: var(--text-brand-default);
    height: 2.5rem;
	font-weight: 600;
}

/* Dark theme styles */
[data-theme="dark"]:root .prev-topic-btn,
[data-theme="dark"]:root .next-topic-btn {
    color: var(--background);
    background-color: var(--button-dark-background);
}

/* Button arrows */
.prev-topic-btn::before {
    content: "←";
    font-size: 1.2rem;
    color: var(--text-brand-default);
    line-height: 1;
    display: flex;
    align-items: center;
	font-weight: 600;
}

.next-topic-btn::after {
    content: "→";
    font-size: 1.2rem;
    color: var(--text-brand-default);
    line-height: 1;
    display: flex;
    align-items: center;
	font-weight: 600;
}

/* Dark theme button arrows */
[data-theme="dark"]:root .prev-topic-btn::before {
    color: var(--background);
}

[data-theme="dark"]:root .next-topic-btn::after {
    color: var(--background);
}

/* Button hover/active states */

.prev-topic-btn:disabled,
.next-topic-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.prev-topic-btn:hover,
.next-topic-btn:hover  {
    transform: scale(1.03);
}

.prev-topic-btn:active,
.next-topic-btn:active {
    transform: scale(0.98);
}
/* Text layout */
.nav-text {
    display: flex;
    flex-direction: row;
    align-items: center;
    text-align: center;
    gap: 0.25rem;
    justify-content: center;
    height: 100%;
    margin: 0;
    color: var(--text-brand-default);
}

.nav-label {
    line-height: 1;
    padding: 0;
    margin: 0;
}

.nav-title {
    font-size: 1rem;
    color: var(--text-brand-default);
    line-height: 1;
    padding: 0;
    margin: 4px 0 0 0;
}

/* Dark theme title color */
[data-theme="dark"]:root .nav-title {
    color: var(--background);
}

/* Alignment for previous/next */
.prev-topic-btn {
    flex-direction: row;
}

.next-topic-btn {
    flex-direction: row;
}

@media (max-width: 600px) {
    .topic-navigation {
        flex-direction: column;
        gap: 1rem;
    }
    
    .prev-topic-btn, 
    .next-topic-btn {
        width: 100%;
    }
}

.topic-navigation-wrapper
{
	height: auto;
	padding: 1em 0 0 0;
	box-sizing: border-box;
	overflow: hidden;
	clear: both;
	color: var(--text-neutral-weakest);
	position: relative;
	z-index: 20;
    margin-right: 1em;
    margin-left: -2.5em;
}

@media (max-width: 1279px)
{
.topic-navigation-wrapper
{

    margin-right: 1em;
    margin-left: 1em;
}
}

.custom-footer-table-top
{
	width: 100%;
	margin-left: auto;
	margin-right: auto;
	font-size: var(--font-size-html);
	line-height: 20px;
	margin-bottom: 0.5em;	
}