/* â€”â€” Top bar: dropdown Vue (tres columnas: grid en app.css / .top-bar-vue-mount) â€”â€” */
#vue-top-bar-app.top-bar-vue-mount {
    position: relative;
    width: 100%;
    max-width: none;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, auto) minmax(0, 1fr);
    grid-template-areas: "left center right";
    align-items: center;
    gap: 8px 12px;
    font-family: var(--rtp-font-ui);
}

#vue-top-bar-app .top-bar-left {
    grid-area: left;
    justify-self: start;
    position: relative;
    z-index: 2;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
}

#vue-top-bar-app .top-bar-center {
    grid-area: center;
    position: static;
    left: auto;
    top: auto;
    transform: none;
    z-index: 1;
    justify-self: center;
    max-width: min(42vw, 380px);
    pointer-events: none;
}

#vue-top-bar-app .top-bar-right {
    grid-area: right;
    justify-self: end;
    position: relative;
    z-index: 5;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    min-width: max-content;
    width: max-content;
    max-width: 100%;
    pointer-events: auto;
}

/* Pizarra coach (XV/7s): nav + JUGADORES no deben empujar fullscreen / compartir fuera de la barra */
#vue-top-bar-app.top-bar-vue-mount--live-coach {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, auto) minmax(min-content, 1fr);
    grid-template-rows: minmax(0, 1fr);
    align-items: center;
}

#vue-top-bar-app.top-bar-vue-mount--live-coach .top-bar-center {
    max-width: min(30vw, 240px);
}

#vue-top-bar-app.top-bar-vue-mount--live-coach .top-bar-center:has(.top-bar-team-mode) ~ .top-bar-right .top-bar-coach-name {
    display: none;
}

.topbar-players-dropdown {
    position: relative;
    flex-shrink: 0;
    max-width: 100%;
}

.topbar-players-dropdown .topbar-players-menu {
    left: 0;
    right: auto;
}

.top-bar-nav-vue {
    position: relative;
    width: auto;
    max-width: min(280px, 42vw);
    min-width: 9.5rem;
    flex-shrink: 0;
    justify-self: start;
    overflow: visible;
}

.top-bar-nav-trigger {
    width: 100%;
    min-width: 9.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px 8px 14px;
    box-sizing: border-box;
    border-radius: 10px;
    border: 1px solid var(--rtp-border);
    background: var(--rtp-surface);
    color: var(--rtp-brand-text);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    cursor: pointer;
    font-family: inherit;
    transition: var(--rtp-transition-ui);
}

.top-bar-nav-trigger:hover {
    border-color: var(--rtp-brand-primary);
    background: var(--rtp-surface-raised);
}

.top-bar-nav-trigger-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.top-bar-nav-chevron {
    flex-shrink: 0;
    font-size: 1.05rem;
    line-height: 1;
    font-weight: 800;
    opacity: 0.92;
}

.top-bar-nav-menu {
    position: absolute;
    left: 0;
    top: calc(100% + 6px);
    right: auto;
    width: max-content;
    min-width: max(100%, 16.25rem);
    max-width: min(340px, 92vw);
    margin: 0;
    padding: 6px;
    list-style: none;
    background: var(--rtp-surface);
    border: 1px solid var(--rtp-border);
    border-radius: 10px;
    box-shadow: var(--rtp-shadow-soft);
    z-index: 10050;
    box-sizing: border-box;
    overflow: hidden;
}

.top-bar-nav-item {
    display: block;
    width: 100%;
    min-width: max-content;
    text-align: left;
    white-space: nowrap;
    padding: 10px 14px;
    box-sizing: border-box;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--rtp-brand-text);
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
    font-family: inherit;
    transition: var(--rtp-transition-ui);
}

.top-bar-nav-item:hover:not(:disabled) {
    background: var(--rtp-surface-raised);
    color: var(--rtp-brand-text);
}

.top-bar-nav-item--disabled,
.top-bar-nav-item:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
