/* Polls (prefix pl-): the answer form and the result bars, used on the participant page, the dashboard and the admin evaluation */

.pl-poll { display: flex; flex-direction: column; gap: .6rem; min-width: 0; }
.pl-poll .wg-top { flex-wrap: wrap; }
.pl-question { overflow-wrap: anywhere; }
.pl-description { overflow-wrap: anywhere; color: var(--color-text-muted); }
.pl-description-short { font-size: .9em; }
.pl-meta { flex-wrap: wrap; }

.pl-hint, .pl-results-note, .pl-change-until { color: var(--color-text-muted); font-size: .85rem; }
.pl-options { display: flex; flex-direction: column; gap: .35rem; margin: .4rem 0 .6rem; }
.pl-option {
    display: flex; align-items: flex-start; gap: .65rem; margin: 0; padding: .6rem .8rem; cursor: pointer;
    border: 1px solid var(--color-border-medium); border-radius: .4rem; overflow-wrap: anywhere; min-width: 0;
    transition: border-color .12s ease, background .12s ease;
}
.pl-option:hover { background: var(--color-surface-light-1); }
.pl-option input { margin-top: .2rem; flex: 0 0 auto; accent-color: var(--color-highlight); }
.pl-option:has(input:checked) {
    border-color: var(--color-highlight);
    background: color-mix(in srgb, var(--color-highlight) 10%, transparent);
}
.pl-option-chosen { cursor: default; border-color: var(--color-highlight); }
.pl-option-chosen i { color: var(--color-highlight); }
.pl-actions { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.pl-mychoice { display: flex; flex-direction: column; gap: .35rem; }

.pl-bars { display: flex; flex-direction: column; gap: .55rem; }
.pl-bar-top { display: flex; justify-content: space-between; gap: .75rem; font-size: .9rem; }
.pl-bar-label { min-width: 0; overflow-wrap: anywhere; }
.pl-bar-value { flex: 0 0 auto; color: var(--color-text-muted); font-variant-numeric: tabular-nums; }
.pl-bar-track { height: .6rem; border-radius: 1rem; background: var(--color-border-light-1); overflow: hidden; margin-top: .2rem; }
.pl-bar-fill { height: 100%; border-radius: 1rem; background: color-mix(in srgb, var(--color-highlight) 45%, transparent); }
.pl-bar-mine .pl-bar-label { font-weight: var(--font-weight-strong); }
.pl-bar-mine .pl-bar-label i { color: var(--color-highlight); }
.pl-bar-mine .pl-bar-fill { background: var(--color-highlight); }


/* dashboard widget */
.pl-pager { display: flex; align-items: center; justify-content: flex-end; gap: .25rem; margin-bottom: .25rem; }
.pl-pager .btn { padding: 0 .35rem; }
.pl-pager-count { color: var(--color-text-muted); font-size: .85rem; font-variant-numeric: tabular-nums; }
.pl-widget-footer { margin-top: .5rem; font-size: .85rem; }

/* admin: options - input and button in one row */
.pl-addoption { align-items: center; }
.pl-addoption input { flex: 1 1 180px; width: auto; min-width: 0; }

/* admin evaluation */
.pl-answers .wg-meta { flex-wrap: wrap; }

/* participant page: the centered detail layout (news, booking ...) */
.pl-topbar { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 16px; }
.pl-topbar .detail-back { margin-bottom: 0; }
.pl-manage { font-size: .85rem; }
.pl-pills { margin: -8px 0 14px 0; }
.pl-lead { margin: 0 0 18px 0; color: var(--color-text-muted); font-size: 1.02rem; line-height: 1.6; }
.pl-page .detail-card { padding: 20px 24px; }
.pl-page .pl-meta { margin-bottom: .2rem; }

/* results: a separated block, the leading option in full colour */
.pl-results { margin-top: .4rem; padding-top: .2rem; }
.pl-form + .pl-results { margin-top: 1rem; padding-top: .8rem; border-top: 1px solid var(--color-border-medium); }
.pl-bar-lead .pl-bar-label { font-weight: var(--font-weight-strong); }
.pl-bar-lead .pl-bar-fill { background: color-mix(in srgb, var(--color-highlight) 75%, transparent); }
.pl-bar-mine.pl-bar-lead .pl-bar-fill { background: var(--color-highlight); }

/* overview: tiles like news, booking, recipes ... (no picture: a tinted head with the icon instead) */
.pl-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.pl-tile {
    display: flex; flex-direction: column; min-width: 0; overflow: hidden;
    border-radius: .3rem; background: var(--color-white); box-shadow: var(--shadow-sm);
    color: var(--color-textprimary); text-decoration: none; overflow-wrap: anywhere;
}
.pl-tile:hover { box-shadow: 0 0 0 2px var(--color-highlight), var(--shadow-sm); text-decoration: none; color: var(--color-textprimary); }
.pl-tile-head {
    display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px;
    background: color-mix(in srgb, var(--color-highlight) 9%, transparent);
}
.pl-tile-icon {
    flex: none; display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%;
    background: color-mix(in srgb, var(--color-highlight) 16%, transparent); color: var(--color-highlight); font-size: 1.2rem;
}
.pl-tile-pills { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.pl-tile-ended .pl-tile-head { background: var(--color-surface-light-1); }
.pl-tile-ended .pl-tile-icon { background: var(--color-surface-light-2); color: var(--color-text-muted); }
.pl-tile-body { flex: 1 1 auto; padding: 14px 16px 6px 16px; }
.pl-tile-title {
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
    margin: 0 0 6px 0; padding: 0; font-size: 1.08rem; font-weight: var(--font-weight-strong); line-height: 1.3; color: var(--color-highlight);
}
.pl-tile-text {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    margin: 0; font-size: .86rem; line-height: 1.45; color: var(--color-text-muted);
}
.pl-tile-foot { display: flex; flex-wrap: wrap; gap: 4px 14px; padding: 10px 16px 14px 16px; font-size: .78rem; color: var(--color-text-muted); }
.pl-tile-foot .la { margin-right: 3px; }
