/* LIVE SESSIONS: the owner's share dialog (opened from the playlist menu) and the guest page */

/* ---- the playlist menu: share row and the LIVE marks ---- */
#plMenu .ls-share-row .ls-share-text {
    min-width: 0;
    max-width: 100%;
}

#plMenu .ls-share-row small {
    display: block;
    overflow: hidden;
    font-weight: 400;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#plMenu .pl-live {
    position: absolute;
    top: 17px;
    left: -3px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #fa5c7c;
    box-shadow: 0 0 0 2px var(--ct-topbar-bg, #fff);
    animation: ls-pulse 1.6s ease-in-out infinite;
}

@keyframes ls-pulse {
    0%, 100% { opacity: 1; }
    50%      { opacity: .35; }
}

/* ---- the dialog ---- */
.ls-invite {
    text-align: center;
    padding: 1rem .5rem .25rem;
}

.ls-invite .ls-logo {
    height: 38px;
    max-width: 70%;
    object-fit: contain;
    margin-bottom: .75rem;
}

.ls-invite .ls-name {
    margin: 0;
    word-break: break-word;
}

.ls-invite .ls-host {
    margin: .25rem 0 1rem;
}

.ls-qr {
    display: inline-block;
    padding: 12px;
    background: #fff;
    border-radius: 12px;
    line-height: 0;
}

.ls-qr svg {
    display: block;
    width: min(66vw, 260px);
    height: auto;
}

.ls-url {
    font-size: .8rem;
}

/* ---- the guest page ---- */
body.ls-guest {
    min-height: 100vh;
}

.ls-bar {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .6rem 1rem;
    border-bottom: 1px solid rgba(128, 128, 128, .25);
    background: var(--ct-topbar-bg, rgba(0, 0, 0, .25));
}

.ls-bar-logo img {
    height: 30px;
}

.ls-bar-title {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.ls-bar-title strong,
.ls-bar-title small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ls-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem;
}

.ls-center {
    text-align: center;
    padding: 4rem 1rem;
}

.ls-song-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .5rem;
}

.ls-song-head h2 {
    word-break: break-word;
}

.ls-tools {
    display: flex;
    align-items: center;
    gap: .35rem;
}

.ls-live-badge i {
    animation: ls-pulse 1.6s ease-in-out infinite;
}

.ls-guest .chords-toggle.active {
    background-color: var(--bs-primary, #727cf5);
    color: #fff;
}

/* narrow phones: long chord/lyric lines scroll inside the card instead of widening the page */
.ls-guest .ls-main { min-width: 0; }
.ls-guest #song-cover { overflow-x: auto; }
.ls-guest .card-body { padding: .75rem; }


/* ---- guest names: the join card and the "who is connected" panel ---- */
.ls-join-card {
    max-width: 420px;
}

.ls-bar {
    position: relative;
}

.ls-people-wrap {
    position: static;
}

.ls-people {
    position: absolute;
    top: calc(100% + 6px);
    right: .75rem;
    z-index: 50;
    width: min(320px, calc(100vw - 1.5rem));
    max-height: 70vh;
    overflow-y: auto;
    padding: .75rem;
    border: 1px solid rgba(128, 128, 128, .3);
    border-radius: .5rem;
    background: var(--ct-card-bg, #37404a);
    box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .35);
}

.ls-people-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .5rem;
}

.ls-person {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .3rem .1rem;
}

.ls-person .ls-person-name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ls-person.ls-me .ls-person-name {
    font-weight: 600;
}

.ls-people-foot {
    margin-top: .5rem;
    padding-top: .5rem;
    border-top: 1px dashed rgba(128, 128, 128, .35);
    font-size: .85rem;
}

/* the owner's dialog: names of the connected guests */
.ls-guest-names {
    margin: .5rem 0 0;
    padding: 0;
    max-height: 120px;
    overflow-y: auto;
    list-style: none;
    font-size: .85rem;
}

.ls-guest-names li {
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .15rem 0;
}
