/* Signature — slim editorial masthead */

.sg-masthead {
    position: sticky;
    top: 0;
    z-index: 900;
    background: rgba(25, 34, 38, 0.94);
    border-bottom: 1px solid rgba(245, 243, 238, 0.08);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.sg-masthead.is-scrolled {
    background: rgba(25, 34, 38, 0.98);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

.sg-masthead__shell {
    width: min(100% - 1.5rem, var(--sg-container));
    margin-inline: auto;
}

.sg-masthead__inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 48px;
    height: 48px;
    padding: 0;
}

.sg-masthead__brand {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
    flex: 1;
    color: var(--sg-ivory);
}

.sg-masthead__signal {
    width: 3px;
    height: 18px;
    flex-shrink: 0;
    background: var(--sg-malachite);
    box-shadow: 0 0 12px rgba(11, 218, 81, 0.45);
}

.sg-masthead__logo {
    width: 26px;
    height: 26px;
    border-radius: 3px;
    object-fit: cover;
    flex-shrink: 0;
}

.sg-masthead__name {
    font-family: var(--sg-font-display);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: -0.02em;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sg-masthead__nav {
    display: none;
    align-items: center;
    gap: 0.15rem;
}

.sg-masthead__link,
.sg-masthead__logout button {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.7rem;
    border: 0;
    background: transparent;
    color: rgba(245, 243, 238, 0.62);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    position: relative;
    transition: color var(--sg-fast);
}

.sg-masthead__link:hover,
.sg-masthead__logout button:hover {
    color: var(--sg-ivory);
}

.sg-masthead__link.is-active {
    color: var(--sg-ivory);
}

.sg-masthead__link.is-active::after {
    content: '';
    position: absolute;
    inset-inline: 0.7rem;
    bottom: 0.1rem;
    height: 1px;
    background: var(--sg-malachite);
}

.sg-masthead__menu-link {
    display: inline-flex;
    flex-shrink: 0;
    padding: 0.3rem 0.7rem;
    border: 1px solid rgba(11, 218, 81, 0.45);
    color: var(--sg-malachite);
    font-size: 0.78rem;
    font-weight: 650;
    letter-spacing: 0.02em;
}

@media (min-width: 992px) {
    .sg-masthead__inner {
        min-height: 52px;
        height: 52px;
    }

    .sg-masthead__nav {
        display: flex;
    }

    .sg-masthead__brand {
        flex: 0 1 auto;
        max-width: 280px;
    }
}
