/* Map taskbar — single new-frame/taskbar-v2 shell. Combat overlay: map-taskbar-combat.css */

#map-taskbar {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: var(--z-ship-nav);
    width: max-content;
    max-width: calc(100vw - 2rem);
    pointer-events: none;
    user-select: none;
}

#map-taskbar,
#map-taskbar * {
    box-sizing: border-box;
}

#ship-navigation-panel {
    position: relative;
    background: none;
    backdrop-filter: none;
    border: none;
    box-shadow: none;
    min-width: 0;
    max-width: none;
    pointer-events: auto;
}

.map-taskbar-plate {
    --tb-w: min(680px, calc(100vw - 2rem));
    --tb-y: calc(var(--tb-w) / 1156);
    position: relative;
    width: var(--tb-w);
    height: calc(var(--tb-y) * 224);
    overflow: visible;
}

.map-taskbar-skin {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: url(/assets/bg-main-C19v7vdo.png) center / 100% 100% no-repeat;
}

.cab-context[hidden] {
    display: none !important;
}

/* ── Nav POI slots (right wing — green taskbar plates) ───────────────────── */

#map-taskbar .cab-slots {
    gap: 0;
}

#map-taskbar .cab-slot {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: calc(var(--tb-y) * 93);
    height: calc(var(--tb-y) * 92);
    padding: 0;
    border: 0;
    border-radius: 0;
    background-color: transparent;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 100% 100%;
    cursor: pointer;
    transition: filter 0.15s ease;
}

/* Right-wing slot positions: map-taskbar-combat.css (.map-taskbar-combat-side--right .cab-slot) */

#ship-navigation-panel .cab-slot::before {
    display: none;
}

#ship-navigation-panel .cab-slot:hover {
    filter: brightness(1.08);
}

#ship-navigation-panel .cab-slot.is-active {
    filter: brightness(1.14);
}

#ship-navigation-panel .cab-slot.is-zero {
    opacity: 1;
}

#ship-navigation-panel .cab-slot.is-zero .cab-slot-icon {
    opacity: 0.52;
}

.cab-slot-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: calc(var(--tb-y) * 44);
    height: calc(var(--tb-y) * 44);
}

#map-taskbar .cab-slot-img {
    display: block;
    width: calc(var(--tb-y) * 44);
    height: calc(var(--tb-y) * 44);
    object-fit: contain;
}

#map-taskbar .cab-slot-icon:has(img) {
    background: none;
}

.cab-slot-badge {
    display: none !important;
}

#map-taskbar .cab-slot .map-taskbar-key {
    top: calc(var(--tb-y) * -20);
    z-index: 1;
}

/* Drawer stacks above the plate (destinations + combat volley/munitions). */
#ship-navigation-panel .cab-drawer,
#ship-navigation-panel .combat-ammo-hud-volley-drawer,
#ship-navigation-panel .combat-ammo-hud-munitions-drawer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 100%;
    margin-bottom: 0.35rem;
    pointer-events: auto;
    z-index: 6;
}

@media (min-width: 640px) {
    #map-taskbar .cab-slots {
        gap: 0;
    }

    #map-taskbar .cab-slot {
        height: calc(var(--tb-y) * 92);
    }

    #map-taskbar .cab-slot:nth-child(1) {
        width: calc(var(--tb-y) * 107);
    }
}

@media (max-width: 767px) {
    #map-taskbar {
        bottom: 12.8dvh;
        max-width: calc(100vw - var(--space-sm) * 2);
    }

    .map-taskbar-plate {
        --tb-w: min(680px, calc(100vw - var(--space-sm) * 2));
    }

    #map-taskbar .map-taskbar-key {
        display: none;
    }

    #map-taskbar .cab-slot {
        height: calc(var(--tb-y) * 92);
    }

    #map-taskbar .cab-slot:nth-child(1) {
        width: calc(var(--tb-y) * 107);
    }

    #map-taskbar .cab-slot.is-zero {
        display: flex;
    }
}
