/* Shared poll panel rows (participants, chat) — global so child components can reuse. */

.poll-participants-row {
    margin-top: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 1rem;
    border: 1px solid rgba(148, 163, 184, 0.22);
    background: rgba(2, 6, 23, 0.92);
    color: rgba(226, 232, 240, 0.98);
}

.poll-participants-row .poll-muted {
    color: rgba(226, 232, 240, 0.78);
}

.poll-participants-row__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.poll-participants-row__header--collapsed {
    margin-bottom: 0;
}

.poll-participants-row__header-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
    flex-wrap: wrap;
}

.poll-participants-row__header-right {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
}

.poll-participants-row__title {
    font-weight: 800;
    font-size: 1rem;
    color: rgba(244, 114, 182, 0.95);
    letter-spacing: 0.01em;
    flex-shrink: 0;
}

.poll-participants-row__summary-inline {
    font-size: 0.95rem;
    white-space: nowrap;
}

.poll-participants-row__empty {
    font-size: 0.95rem;
}

.poll-participants-row__list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.poll-participants-row__list--expanded {
    max-height: 16rem;
    overflow-y: auto;
    overflow-x: hidden;
}

.poll-panel-header-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
    border-radius: 0.5rem;
}

.poll-panel-header-button:focus-visible {
    outline: 2px solid rgba(244, 114, 182, 0.85);
    outline-offset: 2px;
}

.poll-panel-header-button__content {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
    flex-wrap: wrap;
}

.poll-panel-header-button.is-expanded {
    margin-bottom: 0.5rem;
}

.poll-panel-body {
    margin-top: 0;
}

.poll-voter-name-panel .poll-voting__name-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.5rem;
}

.poll-voter-name-panel .poll-voting__name-save {
    height: 2.75rem;
    padding: 0 0.95rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(244, 114, 182, 0.45);
    background: rgba(244, 114, 182, 0.12);
    color: rgba(252, 231, 243, 0.98);
    font-weight: 800;
}

.poll-voter-name-panel .poll-voting__name-save:disabled {
    opacity: 0.55;
}

@media (max-width: 640px) {
    .poll-voter-name-panel .poll-voting__name-row {
        grid-template-columns: 1fr;
    }

    .poll-voter-name-panel .poll-voting__name-save {
        width: 100%;
    }
}

.poll-voter-name-panel .poll-voting__name-ready {
    margin: 0.75rem 0 0;
    font-size: 0.92rem;
    line-height: 1.45;
    color: rgba(167, 243, 208, 0.95);
}

.poll-voter-name-panel .poll-voting__name-pending {
    margin: 0.75rem 0 0;
    font-size: 0.9rem;
    line-height: 1.4;
    color: rgba(244, 114, 182, 0.92);
}

.poll-voter-name-panel .poll-voting__name-warning {
    margin: 0.75rem 0 0;
    font-size: 0.9rem;
    line-height: 1.4;
    color: rgba(251, 191, 36, 0.95);
}

.poll-voter-name-panel .poll-voting__name-label {
    font-weight: 800;
    color: rgba(226, 232, 240, 0.92);
}

@keyframes poll-voter-name-attention {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(244, 114, 182, 0);
        border-color: rgba(148, 163, 184, 0.22);
    }

    35%,
    70% {
        box-shadow: 0 0 0 3px rgba(244, 114, 182, 0.28);
        border-color: rgba(244, 114, 182, 0.55);
    }

    50% {
        box-shadow: 0 0 0 5px rgba(244, 114, 182, 0.12);
        border-color: rgba(244, 114, 182, 0.4);
    }
}

.poll-voter-name-panel--attention {
    animation: poll-voter-name-attention 1.3s ease-in-out 2;
}

@media (prefers-reduced-motion: reduce) {
    .poll-voter-name-panel--attention {
        animation: none;
        border-color: rgba(244, 114, 182, 0.75);
        box-shadow: 0 0 0 2px rgba(244, 114, 182, 0.35);
    }
}

.poll-collapse-toggle {
    border: 0;
    background: transparent;
    color: rgba(226, 232, 240, 0.9);
    padding: 0.2rem 0.35rem;
    border-radius: 0.5rem;
    line-height: 1;
    cursor: pointer;
}

.poll-collapse-toggle:focus-visible {
    outline: 2px solid rgba(244, 114, 182, 0.85);
    outline-offset: 2px;
}

.poll-collapse-toggle__chevron {
    display: inline-block;
    font-size: 1.15rem;
    transition: transform 0.15s ease;
}

.poll-collapse-toggle__chevron:not(.is-expanded) {
    transform: rotate(-90deg);
}

.poll-activity-badge {
    display: inline-flex;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.12rem 0.45rem;
    border-radius: 999px;
    background: rgba(244, 114, 182, 0.22);
    color: rgba(252, 231, 243, 0.98);
    border: 1px solid rgba(244, 114, 182, 0.45);
    white-space: nowrap;
}

.poll-participants-row .poll-link-button {
    border: 0;
    background: transparent;
    color: rgba(226, 232, 240, 0.9);
    font-weight: 700;
    padding: 0.25rem 0.35rem;
    border-radius: 0.5rem;
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.poll-participants-row .poll-link-button:focus-visible {
    outline: 2px solid rgba(244, 114, 182, 0.85);
    outline-offset: 2px;
}

.poll-participants-row .form-control,
.poll-participants-row .form-select {
    background: rgba(15, 23, 42, 0.65);
    border-color: rgba(148, 163, 184, 0.35);
    color: rgba(226, 232, 240, 0.98);
}

.poll-participants-row .form-control::placeholder {
    color: rgba(148, 163, 184, 0.85);
}

.poll-participants-row .form-label,
.poll-participants-row .form-text {
    color: rgba(226, 232, 240, 0.78);
}
