/* ==========================================================
   HEADER
   ========================================================== */

.site-header {
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.site-navbar {
    width: 100%;
    background:
        linear-gradient(
            90deg,
            rgba(15, 23, 42, 0.98),
            rgba(30, 41, 59, 0.96),
            rgba(15, 23, 42, 0.98)
        );
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.site-navbar::before {
    content: "";
    display: block;
    width: 100%;
    height: 3px;
    background: linear-gradient(
        90deg,
        #38bdf8,
        #6366f1,
        #a855f7,
        #38bdf8
    );
}

.site-navbar__inner {
    width: min(1200px, 92%);
    height: 74px;
    margin: 0 auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

/* ==========================================================
   BRAND / LOGO
   ========================================================== */

.site-navbar__brand {
    display: inline-flex;
    align-items: center;
    gap: 13px;

    color: #ffffff;
    text-decoration: none;
    font-weight: 700;

    min-width: 0;
}

.site-navbar__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 52px;
    height: 52px;

    flex: 0 0 auto;

    border-radius: 18px;
    overflow: hidden;

    background: #7dd3fc;

    box-shadow:
        0 12px 32px rgba(56, 189, 248, 0.32),
        inset 0 1px 0 rgba(255, 255, 255, 0.28);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.site-navbar__logo img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.site-navbar__brand:hover .site-navbar__logo {
    transform: translateY(-1px) scale(1.03);
    box-shadow:
        0 16px 38px rgba(56, 189, 248, 0.42),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

/* ==========================================================
   HEADER TITLE
   ========================================================== */

.site-navbar__title {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;

    min-width: 0;

    line-height: 1.05;
    white-space: nowrap;
}

.site-navbar__title-main {
    color: #ffffff;

    font-size: 1.22rem;
    font-weight: 850;
    letter-spacing: 0.005em;
}

.site-navbar__title-sub {
    color: #cbd5e1;

    margin-top: 4px;

    font-size: 0.92rem;
    font-weight: 400;
    letter-spacing: 0.035em;
}

/* ==========================================================
   NAVIGATION
   ========================================================== */

.site-navbar__links {
    display: flex;
    align-items: center;
    gap: 8px;

    padding: 7px;
    border-radius: 999px;

    background: rgba(2, 6, 23, 0.36);
    border: 1px solid rgba(148, 163, 184, 0.14);
}

.site-navbar__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 38px;
    padding: 0 17px;

    border-radius: 999px;
    border: none;

    background: transparent;
    color: #cbd5e1;

    text-decoration: none;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1;

    cursor: pointer;

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

.site-navbar__link:hover {
    color: #ffffff;
    background: rgba(56, 189, 248, 0.16);
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(56, 189, 248, 0.12);
}

.site-navbar__link:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.9);
    outline-offset: 3px;
}

/* ==========================================================
   LOGOUT FORM / BUTTON
   ========================================================== */

.site-navbar__logout-form {
    margin: 0;
    padding: 0;

    display: inline-flex;
    align-items: center;
}

.site-navbar__link--button {
    appearance: none;
    -webkit-appearance: none;

    border: none;
    outline: none;

    font: inherit;
    line-height: 1;

    background: transparent;
    cursor: pointer;
}

.site-navbar__link--button:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.9);
    outline-offset: 3px;
}

/* ==========================================================
   OPTIONAL ADMIN-LINK
   ========================================================== */

.site-navbar__link--admin {
    color: #94a3b8;
}

.site-navbar__link--admin:hover {
    background: rgba(168, 85, 247, 0.18);
    box-shadow: 0 8px 24px rgba(168, 85, 247, 0.12);
}

/* ==========================================================
   RESPONSIVE HEADER
   ========================================================== */

@media (max-width: 1040px) {
    .site-navbar__inner {
        gap: 18px;
    }

    .site-navbar__title-main {
        font-size: 1.14rem;
    }

    .site-navbar__title-sub {
        font-size: 0.86rem;
    }

    .site-navbar__link {
        padding: 0 14px;
    }
}

@media (max-width: 700px) {
    .site-navbar__inner {
        height: auto;
        padding: 16px 0;
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
    }

    .site-navbar__brand {
        justify-content: center;
    }

    .site-navbar__logo {
        width: 50px;
        height: 50px;
        border-radius: 17px;
    }

    .site-navbar__title {
        align-items: flex-start;
    }

    .site-navbar__title-main {
        font-size: 1.16rem;
    }

    .site-navbar__title-sub {
        margin-top: 4px;
        font-size: 0.88rem;
    }

    .site-navbar__links {
        justify-content: center;
        flex-wrap: wrap;
        border-radius: 24px;
    }

    .site-navbar__link {
        flex: 1 1 auto;
        padding: 0 14px;
    }

    .site-navbar__logout-form {
        flex: 1 1 auto;
    }

    .site-navbar__logout-form .site-navbar__link {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .site-navbar__brand {
        gap: 11px;
    }

    .site-navbar__logo {
        width: 46px;
        height: 46px;
        border-radius: 16px;
    }

    .site-navbar__title-main {
        font-size: 1.08rem;
    }

    .site-navbar__title-sub {
        font-size: 0.82rem;
        letter-spacing: 0.03em;
    }

    .site-navbar__links {
        gap: 6px;
        padding: 6px;
    }

    .site-navbar__link {
        min-height: 36px;
        font-size: 0.9rem;
    }
}