﻿/* Sidebar glasanje — izolirano od blog tipografije. */
.pu-glasanje {
    box-sizing: border-box;
    width: 100%;
    padding: 22px;
    border: 1px solid #e0e6ea;
    border-top: 3px solid #ffcf32;
    border-radius: 12px;
    background: #fff;
    color: #263643;
    font-family: Arial, Helvetica, sans-serif;
    text-align: left;
}

    .pu-glasanje h3 {
        margin: 0 0 20px;
        color: #263643;
        font-family: inherit;
        font-size: 21px;
        font-weight: 700;
        line-height: 1.3;
        text-transform: none;
    }

    .pu-glasanje p {
        margin: 10px 0;
        font-family: inherit;
        font-size: 13px;
        line-height: 1.6;
    }

.pu-glasanje-izbor {
    display: block;
    min-width: 0;
    margin: 0 0 20px;
    padding: 0;
    border: 0;
}

    .pu-glasanje-izbor legend {
        display: block;
        width: 100%;
        margin: 0 0 12px;
        padding: 0;
        border: 0;
        font-size: 13px;
        line-height: 1.5;
    }

.pu-glasanje-rating {
    position: relative;
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 7px;
}

    .pu-glasanje-rating input {
        position: absolute;
        width: 1px;
        height: 1px;
        opacity: 0;
    }

    .pu-glasanje-rating label {
        display: flex;
        flex-direction: column;
        align-items: center;
        margin: 0;
        cursor: pointer;
    }

        .pu-glasanje-rating label span {
            color: #bdcbd5;
            font-size: 34px;
            line-height: 1.2;
        }

        .pu-glasanje-rating label small {
            margin-top: 7px;
            color: #607383;
            font-size: 11px;
        }

    .pu-glasanje-rating input:checked ~ label span {
        color: #eab600;
    }

    .pu-glasanje-rating input:focus-visible + label {
        outline: 2px solid #258eaf;
        outline-offset: 3px;
        border-radius: 3px;
    }

.pu-glasanje-stars {
    display: flex;
    gap: 7px;
    color: #bdcbd5;
    font-size: 34px;
}

    .pu-glasanje-stars .odabrana {
        color: #eab600;
    }

.pu-glasanje button {
    display: inline-block;
    margin: 0;
    padding: 12px 18px;
    border: 0;
    border-radius: 7px;
    background: #ffcf32;
    color: #263643;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.pu-glasanje-note {
    display: block;
    margin-top: 11px;
    color: #71808b;
    font-size: 11px;
    line-height: 1.6;
}

.pu-glasanje a {
    color: #258eaf;
    font-weight: 700;
}

.pu-glasanje-rezultati {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #e0e6ea;
    font-size: 13px;
}

.pu-glasanje-red {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) 28px;
    align-items: center;
    gap: 10px;
    margin: 11px 0;
    font-size: 12px;
}

    .pu-glasanje-red > span:last-child {
        text-align: right;
    }

.pu-glasanje-bar {
    height: 7px;
    overflow: hidden;
    border-radius: 10px;
    background: #edf2f5;
}

    .pu-glasanje-bar i {
        display: block;
        height: 100%;
        border-radius: inherit;
        background: #ffcf32;
    }

/* Polje pitanja u administraciji. */
textarea.pu-glasanje-pitanje {
    box-sizing: border-box;
    display: block;
    width: 100%;
    max-width: none;
    min-height: 120px;
    margin: 8px 0 16px;
    padding: 14px 16px;
    border: 1px solid #cbd5dd;
    border-radius: 8px;
    background: #fff;
    color: #263643;
    font: inherit;
    font-size: 16px;
    line-height: 1.5;
    resize: vertical;
}

    textarea.pu-glasanje-pitanje:focus {
        border-color: #258eaf;
        outline: 2px solid #258eaf;
        outline-offset: 2px;
    }

/* Kompaktan admin obrazac. */
.pu-glasanje-admin {
    max-width: 980px;
}

    .pu-glasanje-admin fieldset {
        margin: 0 0 18px;
        padding: 0;
        border: 0;
    }

    .pu-glasanje-admin label {
        margin: 0 0 6px;
    }

    .pu-glasanje-admin textarea.pu-glasanje-pitanje {
        min-height: 85px;
        margin-bottom: 0;
        padding: 10px 12px;
        font-size: 15px;
    }

.pu-glasanje-datumi {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

    .pu-glasanje-datumi label {
        display: block;
    }

    .pu-glasanje-datumi input {
        box-sizing: border-box;
        width: 100%;
        padding: 7px 9px;
    }

.pu-glasanje-admin .hint {
    margin: 7px 0 0;
    font-size: 12px;
}

.pu-glasanje-admin legend {
    margin-bottom: 10px;
    font-size: 15px;
}

.pu-glasanje-role {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px 18px;
}

    .pu-glasanje-role label {
        display: flex;
        align-items: center;
        gap: 7px;
        margin: 0;
        font-size: 13px;
        line-height: 1.5;
    }

    .pu-glasanje-role input[type="checkbox"] {
        flex: 0 0 auto;
        margin: 0;
    }

@media (max-width: 800px) {
    .pu-glasanje-role {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 580px) {
    .pu-glasanje-datumi {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .pu-glasanje-role {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Podrška postojećem widgetu pri zamjeni datoteka. */
.pu-glasanje-izbor > label {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    width: 35px;
    margin: 0 4px 0 0;
    cursor: pointer;
}

    .pu-glasanje-izbor > label > input {
        position: absolute;
        width: 1px;
        height: 1px;
        opacity: 0;
    }

    .pu-glasanje-izbor > label > span {
        color: #bdcbd5;
        font-size: 34px;
        line-height: 1.2;
    }

    .pu-glasanje-izbor > label > small {
        display: block;
        margin-top: 7px;
        color: #607383;
        font-size: 11px;
    }

    .pu-glasanje-izbor > label:has(input:checked) > span,
    .pu-glasanje-izbor > label:has(~ label input:checked) > span {
        color: #eab600;
    }

    .pu-glasanje-izbor > label:has(input:focus-visible) {
        outline: 2px solid #258eaf;
        outline-offset: 3px;
    }

.pu-glasanje-red > meter {
    display: block;
    width: 100%;
    min-width: 0;
    height: 10px;
}

/* Hover prikazuje ocjenu; izlazak miša vraća odabranu vrijednost. */
@media (hover: hover) and (pointer: fine) {
    .pu-glasanje .pu-glasanje-rating:has(label:hover) label span,
    .pu-glasanje .pu-glasanje-izbor:has(> label:hover) > label > span {
        color: #bdcbd5;
    }

    .pu-glasanje .pu-glasanje-rating:has(label:hover) label:hover span,
    .pu-glasanje .pu-glasanje-rating:has(label:hover) label:hover ~ label span,
    .pu-glasanje .pu-glasanje-izbor:has(> label:hover) > label:hover > span,
    .pu-glasanje .pu-glasanje-izbor:has(> label:hover) > label:has(~ label:hover) > span {
        color: #eab600;
    }
}
/* Poziv neprijavljenim korisnicima. */
.pu-glasanje-najava {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    color: #eab600;
    font-size: 34px;
    line-height: 1;
}

.pu-glasanje-gost p {
    margin: 0 0 16px;
    color: #607383;
    font-size: 14px;
}

.pu-glasanje a.pu-glasanje-prijava {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 7px;
    background: #ffcf32;
    color: #263643;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
}

    .pu-glasanje a.pu-glasanje-prijava:hover {
        background: #f3c124;
    }

    .pu-glasanje a.pu-glasanje-prijava:focus-visible {
        outline: 2px solid #258eaf;
        outline-offset: 3px;
    }
