/* =========================
   GLOBAL
========================= */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
}

body {
    font-family:
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    line-height: 1.6;

    background: #f5f6f8;
    color: #222;

    display: flex;
    flex-direction: column;

    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}


/* =========================
   TOP BAR
========================= */

.site-header {
    width: 100%;
}

.navbar {
    width: 100%;

    background: #1f2937;
    color: white;

    box-shadow:
        0 2px 6px rgba(0, 0, 0, 0.15);
}

.navbar-inner {
    width: 100%;
    max-width: 1400px;

    margin: 0 auto;

    min-height: 64px;

    padding:
        0 24px;

    display: flex;
    align-items: center;
    justify-content: space-between;
}


/* Logo */

.site-logo {
    font-size: 1.25rem;
    font-weight: 700;

    white-space: nowrap;
}

.site-logo:hover {
    text-decoration: none;
}


/* Navigation */

.main-navigation {
    display: flex;
    align-items: center;

    gap: 6px;
}

.main-navigation a,
.logout-form button {
    border: 0;

    background: transparent;
    color: white;

    padding:
        9px 13px;

    border-radius: 6px;

    font: inherit;

    cursor: pointer;
}

.main-navigation a:hover,
.logout-form button:hover {
    background: rgba(255, 255, 255, 0.12);

    text-decoration: none;
}


/* Login */

.login-button {
    background: rgba(255, 255, 255, 0.15) !important;
}


/* Logout */

.logout-form {
    margin: 0;
}


/* =========================
   MOBILE MENU BUTTON
========================= */

.menu-toggle {
    display: none;

    border: 0;

    background: transparent;
    color: white;

    font-size: 1.7rem;

    cursor: pointer;

    padding: 8px;
}


/* =========================
   MAIN
========================= */

.site-main {
    flex: 1;

    width: 100%;
}

.content-container {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto;

    padding:
        40px 24px;
}


/* =========================
   FOOTER
========================= */

.site-footer {
    width: 100%;

    background: #1f2937;
    color: white;

    margin-top: auto;
}

.footer-inner {
    width: 100%;
    max-width: 1400px;

    margin: 0 auto;

    padding:
        35px 24px;

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 40px;
}

.footer-section {
    display: flex;
    flex-direction: column;

    gap: 6px;
}

.footer-section strong {
    margin-bottom: 6px;

    font-size: 1.05rem;
}

.footer-section p {
    margin: 0;

    opacity: 0.8;
}

.footer-section a {
    opacity: 0.85;
}

.footer-section a:hover {
    opacity: 1;

    text-decoration: underline;
}


/* Bottom line */

.footer-bottom {
    width: 100%;

    border-top:
        1px solid rgba(255, 255, 255, 0.12);

    padding:
        15px 24px;

    text-align: center;

    font-size: 0.9rem;

    opacity: 0.75;
}


/* =========================
   TABLET
========================= */

@media (max-width: 900px) {

    .main-navigation {
        gap: 2px;
    }

    .main-navigation a,
    .logout-form button {
        padding:
            8px 9px;

        font-size: 0.95rem;
    }

    .account-toggle {
        max-width: 145px;
        padding: 8px 9px;
    }

}


/* =========================
   MOBILE
========================= */

@media (max-width: 700px) {

    .navbar-inner {
        min-height: 58px;

        padding:
            0 16px;
    }


    .menu-toggle {
        display: block;
    }


    .main-navigation {

        display: none;

        position: absolute;

        left: 0;
        right: 0;

        top: 58px;

        background: #1f2937;

        flex-direction: column;

        align-items: stretch;

        padding: 10px 16px 16px;

        box-shadow:
            0 4px 8px rgba(0, 0, 0, 0.2);

        z-index: 1000;
    }


    .main-navigation.navigation-open {
        display: flex;
    }

    /* Account gets its own full-width row on mobile */

    .account-menu {
        width: 100%;
        margin-top: 4px;
        padding-top: 4px;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
    }

    .account-toggle {
        width: 100%;
        max-width: none;
        justify-content: flex-start;
        padding: 12px;
    }

    .account-name {
        flex: 1 1 auto;
        overflow: visible;
        text-overflow: clip;
        white-space: normal;
    }

    .account-dropdown {
        position: static;
        width: 100%;
        min-width: 0;
        margin-top: 2px;
        padding: 0;
        background: transparent;
        border-radius: 0;
        box-shadow: none;
    }

    .account-dropdown a,
    .account-dropdown .logout-form button {
        width: 100%;
        padding: 12px;
        border-radius: 6px;
    }



    .main-navigation a,
    .logout-form button {

        width: 100%;

        text-align: left;

        padding: 12px;

        border-radius: 6px;
    }


    .logout-form {
        width: 100%;
    }


    /* Main */

    .content-container {
        padding:
            25px 16px;
    }


    /* Footer */

    .footer-inner {

        grid-template-columns: 1fr;

        gap: 25px;

        padding:
            30px 16px;
    }


    .footer-bottom {
        padding:
            14px 16px;
    }

}