:root {
    color-scheme: dark;
    --page-bg: #121212;
    --text: #f8fafc;
    --surface: #1e293b;
    --strong: #f8fafc;
    --muted: #cbd5e1;
    --line: #475569;
    --accent: #93c5fd;
    --hover-bg: #1e293b;
    --progress-track: #334155;
    --button-hover-bg: #f1f5f9;
    --button-hover-text: #0f172a;
    --nav-shadow: rgba(0, 0, 0, 0.3);
    --nav-shadow-strong: rgba(0, 0, 0, 0.5);
}

body.light {
    color-scheme: light;
    --page-bg: #d9dde3;
    --text: #172033;
    --surface: #c5cbd3;
    --strong: #1e293b;
    --muted: #475569;
    --line: #8f9aaa;
    --accent: #002fa7;
    --hover-bg: #c9ced6;
    --progress-track: #b8c0cb;
    --button-hover-bg: #334155;
    --button-hover-text: #f8fafc;
    --nav-shadow: rgba(15, 23, 42, 0.14);
    --nav-shadow-strong: rgba(15, 23, 42, 0.24);
}

body {
    min-height: 100vh;
    margin: 0;
    background-color: var(--page-bg);
    color: var(--text);
    transition:
        background-color 0.3s ease,
        color 0.3s ease;

    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

html:lang(ka) body {
    font-family: "Noto Sans Georgian", sans-serif;
}

html {
    font-size: 125%;
}

section {
    scroll-margin-top: 90px;
}

main > section {
    min-height: 65vh;
}

nav {
    max-width: 1450px;
    margin: 0 auto;
    padding: 10px 20px;

    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 3rem;

    background-color: var(--surface);
    border-radius: 12px;

    box-shadow: 0 2px 8px var(--nav-shadow);

    position: sticky;
    top: 0;
    z-index: 100;

    transform: translateY(12px);

    transition:
        background-color 0.3s ease,
        box-shadow 0.3s ease;
}

nav.scrolled {
    box-shadow: 0 4px 18px var(--nav-shadow-strong);
}

#menu-toggle {
    display: none;
}

.navigation {
    list-style: none;

    display: flex;
    align-items: center;

    margin: 0;
    padding: 0;
}

.navigation a {
    display: inline-block;

    text-decoration: none;
    color: inherit;

    font-size: larger;

    transition:
        color 0.3s ease,
        transform 0.3s ease;
}

.navigation a:hover {
    cursor: pointer;
    color: var(--accent);
    transform: scale(1.08);
}

.navigation a[aria-current="page"] {
    color: var(--accent);
}

.navigation li:not(:last-child)::after {
    content: "|";

    color: var(--line);

    margin: 0 15px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

#mode,
#language {
    border: 1px solid var(--line);
    border-radius: 50px;

    padding: 10px 15px;

    background-color: transparent;
    color: inherit;
    font: inherit;

    cursor: pointer;

    transition:
        background-color 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease,
        transform 0.3s ease;
}

#mode:hover,
#language:hover {
    background-color: var(--button-hover-bg);
    color: var(--button-hover-text);
    border-color: var(--button-hover-bg);

    transform: scale(1.08);
}

.footer {
    width: 100%;

    margin-top: 80px;
    padding: 20px 0;
}

.footer .container {
    max-width: 1200px;

    margin: 0 auto;
    padding: 0 20px;
}

.footer-content {
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-copyright {
    margin: 0;

    color: var(--muted);

    font-size: 0.9375rem;
}

@media (max-width: 768px) {
    html {
        font-size: 100%;
    }

    nav {
        margin: 0 10px;
        padding: 8px 10px;
        gap: 8px;
    }

    nav > img {
        display: none;
    }

    #menu-toggle {
        display: inline-flex;
        flex: 0 0 40px;
        width: 40px;
        height: 40px;
        align-items: center;
        justify-content: center;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: transparent;
        color: inherit;
        font: inherit;
        font-size: 1.25rem;
        line-height: 1;
        cursor: pointer;
    }

    .navigation {
        display: none;
        position: absolute;
        top: calc(100% + 8px);
        right: 0;
        left: 0;
        z-index: 101;
        padding: 8px 12px;
        flex-direction: column;
        align-items: stretch;
        background-color: var(--surface);
        border: 1px solid var(--line);
        border-radius: 12px;
        box-shadow: 0 4px 18px var(--nav-shadow-strong);
    }

    nav.menu-open .navigation {
        display: flex;
    }

    .navigation li:not(:last-child)::after {
        display: none;
    }

    .navigation a {
        display: flex;
        min-height: 44px;
        align-items: center;
        padding: 8px 4px;
        border-bottom: 1px solid var(--line);
        font-size: 1rem;
        line-height: 1.3;
    }

    .navigation li:last-child a {
        border-bottom: 0;
    }

    .nav-actions {
        width: auto;
        gap: 6px;
    }

    #mode,
    #language {
        padding: 7px 10px;
        font-size: 0.8rem;
        white-space: nowrap;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .footer {
        margin-top: 50px;
    }
}
