/*
 * SunucuRadar mobil üst menü
 * Yalnız ortak topbar ve hesap menüsü davranışını yönetir.
 */

.mobile-nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 44px;
    padding: 10px 14px;
    border: 1px solid rgba(34, 197, 94, .30);
    border-radius: 13px;
    background: rgba(34, 197, 94, .10);
    color: #d1fae5;
    font: inherit;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
}

.mobile-nav-toggle:hover,
.mobile-nav-toggle:focus-visible {
    background: rgba(34, 197, 94, .18);
    border-color: rgba(74, 222, 128, .50);
    outline: none;
}

.mobile-nav-toggle-icon {
    position: relative;
    width: 20px;
    height: 14px;
    display: inline-block;
    border-top: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
}

.mobile-nav-toggle-icon::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 4px;
    border-top: 2px solid currentColor;
}

.account-menu.is-open .account-dropdown {
    display: block;
}

@media (max-width: 920px) {
    .topbar {
        width: min(100% - 24px, 1180px);
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: 12px;
        padding: 14px 0;
    }

    .brand {
        min-width: 0;
    }

    .mobile-nav-toggle {
        display: inline-flex;
    }

    .topbar > .nav {
        grid-column: 1 / -1;
        width: 100%;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 7px;
        padding: 10px;
        overflow: visible;
        border: 1px solid rgba(34, 197, 94, .22);
        border-radius: 18px;
        background: rgba(7, 10, 15, .97);
        box-shadow: 0 22px 70px rgba(0, 0, 0, .42);
        backdrop-filter: blur(14px);
    }

    .topbar.nav-open > .nav {
        display: flex;
    }

    .topbar > .nav > a,
    .topbar > .nav .account-trigger {
        width: 100%;
        min-height: 46px;
        display: flex;
        align-items: center;
        justify-content: flex-start;
        padding: 12px 14px;
        text-align: left;
        white-space: normal;
    }

    .topbar > .nav > a.active {
        color: #86efac;
        background: rgba(34, 197, 94, .13);
    }

    .account-menu {
        width: 100%;
    }

    .account-dropdown {
        position: static;
        width: 100%;
        min-width: 0;
        margin-top: 7px;
        border-radius: 14px;
        box-shadow: none;
        backdrop-filter: none;
    }

    .account-menu:hover .account-dropdown {
        display: none;
    }

    .account-menu.is-open .account-dropdown {
        display: block;
    }

    .account-dropdown a {
        min-height: 44px;
        display: flex;
        align-items: center;
        padding: 11px 14px;
    }
}

@media (max-width: 480px) {
    .topbar {
        width: min(100% - 18px, 1180px);
    }

    .brand {
        font-size: 16px;
    }

    .brand-mark {
        width: 32px;
        height: 32px;
    }

    .mobile-nav-toggle {
        min-width: 46px;
        padding: 10px 12px;
    }

    .mobile-nav-toggle-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        clip-path: inset(50%);
        white-space: nowrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mobile-nav-toggle {
        transition: none;
    }
}
